campaigns to attack Wei's western borders, but failed to make any significant territorial gains. Sima Zhao felt that Shu was growing weak and lacking in resources after all the campaigns, hence he wanted to launch a large-scale invasion of Shu to eliminate it. Among those he consulted, only Zhong Hui agreed that Shu could be conquered. Zhong Hui assisted Sima Zhao in formulating a strategy for the conquest of Shu. In the winter of 262–263, Zhong Hui was appointed General Who Guards the West () and granted imperial authority to manage military affairs in the Guanzhong region. Sima Zhao also mobilised military forces from the various provinces in Wei and ordered Tang Zi to oversee the construction of warships in preparation for an invasion on Wei's other rival state, Eastern Wu. In the autumn of 263, the Wei imperial court issued an edict ordering Deng Ai and Zhuge Xu to lead 30,000 troops each and attack Shu from two directions: Deng Ai's force would pass through Gansong (甘松; southeast of present-day Têwo County, Gansu) and Tazhong (沓中; northwest of present-day Zhugqu County, Gansu), and engage Jiang Wei's army; Zhuge Xu's force would pass through Wujie Bridge (武街橋; northwest of present-day Wen County, Gansu) and block Jiang Wei's retreat route. Zhong Hui led another army, numbering some 100,000 men, and entered Shu territory via the Xie Valley (斜谷; southwest of present-day Mei County, Shaanxi) and Luo Valley (駱谷; southwest of present-day Zhouzhi County, Shaanxi). Zhong Hui ordered Xu Yi, a son of the veteran Wei general Xu Chu, to oversee the construction of a road leading into Shu. However, when the road turned out to be poorly built, Zhong Hui disregarded Xu Yi's background and had him executed for failing his mission. The Wei army was shocked at Zhong Hui's audacity. Engagements with Shu forces In response to the Wei invasion, the Shu government ordered its armed forces to refrain from engaging the enemy and instead retreat to Hancheng (漢城; east of present-day Mian County, Shaanxi) and Lecheng (樂城; east of present-day Chenggu County, Shaanxi) and hold their positions. Liu Qin (), the Administrator of the Wei-controlled Weixing Commandery (魏興郡; around present-day Ankang, Shaanxi), led his army through the Ziwu Valley (子午谷; east of present-day Yang County, Shaanxi) towards the Shu-controlled Hanzhong Commandery. The Shu officers Wang Han () and Jiang Bin () defended Hancheng and Lecheng respectively with 5,000 troops