Taghliqs, which caused much resentment, and resulted in his assassination in 1670. He was succeeded by his son who ruled for only a brief period before Ismail Khan was enthroned. Ismail reversed the power struggle between the two Muslim factions and drove out the Aq Taghliq leader, Afaq Khoja. Afaq fled to Tibet, where the 5th Dalai Lama aided him in enlisting the help of Galdan Boshugtu Khan, ruler of the Dzungar Khanate. In 1680, Galdan led 120,000 Dzungars into the Yarkent Khanate. They were aided by the Aq Taghliqs and Hami and Turpan, which had already submitted to the Dzungars. Ismail's son Babak Sultan died in the resistance against them in the battle for Kashgar. The general Iwaz Beg died in the defense of Yarkand. The Dzungars defeated the Moghul forces without much difficulty and took Ismail and his family prisoner. Galdan installed Abd ar-Rashid Khan II, son of Babak, as puppet khan. The new khan forced Afaq Khoja to flee again, but Abd ar-Rashid's reign was also ended unceremoniously two years later when riots erupted in Yarkand. He was replaced by his brother Muhammad Imin Khan. Muhammad sought help from the Qing dynasty, Khanate of Bukhara, and the Mughal Empire in combating the Dzungars. In 1693, Muhammad conducted a successful attack on the Dzungar Khanate, taking 30,000 captives. Unfortunately Afaq Khoja appeared again and overthrew Muhammad in a revolt led by his followers. Afaq's son Yahiya Khoja was enthroned but his reign was cut short in 1695 when both he and his father were killed while suppressing local rebellions. In 1696, Akbash Khan was placed on the throne, but the begs of Kashgar refused to recognize him, and instead allied with the Kyrgyz to attack Yarkand, taking Akbash prisoner. The begs of Yarkand went to the Dzungars, who sent troops and ousted the Kyrgyz in 1705. The Dzungars installed a non-Chagatayid ruler Mirza Alim Shah Beg, thereby ending the rule of Chagatai khans forever. Government The Chagatai Mongols remained mostly nomadic in their mode of government and did not settle down in urban centers until the late 15th century. The Mongols of the Chagatai Khanate treated the urban dwellers of Transoxiana and the Tarim Basin as dependencies. Family tree See also List of Chagatai khans List of Mongol states List of Turkic dynasties and countries Division of the Mongol Empire References Citations Sources Barnes, Ian, Bhikhu Parekh and