How did the Opium War affect China?