any dealings with Huang Hao. Huang Hao disliked Xi Zheng, an inner office official who was familiar with Huang Hao's dealings for about 30 years. Although he did not harm Xi Zheng, he never allowed Xi Zheng to get promoted. Liu Yong, a younger brother of Liu Shan, hated Huang Hao and was never on good terms with him. After Huang Hao came to power, he slandered and spoke ill of Liu Yong in front of Liu Shan, resulting in Liu Shan refusing to meet Liu Yong for more than 10 years. In 262, the Shu general Jiang Wei wrote to Liu Shan to urge him to execute Huang Hao. However, Liu Shan refused, said that Huang Hao was merely a servant running errands for him, and told Jiang Wei not to be so upset with Huang Hao. Jiang Wei knew that Huang Hao had many supporters in the imperial court and was concerned that he might have fallen out of favour with the emperor when he asked Liu Shan to execute Huang Hao. Later, Liu Shan ordered Huang Hao to apologise to Jiang Wei. Jiang Wei found an excuse to leave Chengdu and move to a military garrison at Tazhong (沓中; northwest of present-day Zhugqu County, Gansu). In the meantime, Huang Hao tried to remove Jiang Wei from his command and replace him with Yan Yu (閻宇), Huang Hao's close friend. When Jiang Wei heard about it, he remained in Tazhong and refused to return to Chengdu as he knew that he would be safe in Tazhong. In 263, Jiang Wei received news that Zhong Hui, a general from Shu's rival state Wei, was mobilising troops into the Guanzhong region, seemingly in preparation for an invasion of Shu. He then wrote to Liu Shan, requesting permission to set up defences against the impending invasion. Huang Hao, who believed in sorcery, got a witch doctor to predict the future. He then told Liu Shan that the witch doctor predicted that the Wei forces would not attack Shu, so there was no need to follow Jiang Wei's plan. Later that year, the Wei general Deng Ai led his troops through a shortcut across mountainous terrain, bypassing the Shu defences, and arriving outside Chengdu. Liu Shan surrendered without putting up a fight, thus bringing an end to the Shu regime's existence. After Liu Shan's surrender, Deng Ai heard that Huang Hao was