and replaced by Gao Di (), who ordered a general retreat to Shanhai Pass. However, Yuan flatly refused to leave Ningyuan. Early in the next year, Nurhaci led the Jurchens back across the Liao River. Yuan and his deputies successfully held Ningyuan with the newly mounted and modified "hongyipao" and only 9,000 militiamen against Nurhaci's 130,000-strong army. The victory at Ningyuan prevented immediate advances by the Jurchens. Yuan was said to have studied every aspect of the cannon for it to fire accurately at the position he wanted, and this is given as the reason why Nurhaci, although well-protected by his elite guards in a safe position, was wounded by cannon fire. After the battle, Yuan sent letters to ask the well-being of Nurhaci, as traditionally done by Chinese generals, but Nurhaci returned an insult by calling him duplicitous. As a result of this victory, the Ming imperial court in Beijing appointed Yuan as the Governor of Liaodong on 27 February 1626, with full authority to handle all forces outside the passes. During this time, Yuan executed Mao Wenlong, a Ming general regarded as ruthless but talented. Various texts have different opinions of his actions. Many stated this was a mistake since Mao could still be used against the Jurchens. However, Yuan took into account how Mao conducted his battles: Mao's tactics usually involved using civilian settlements as a shield for his troops, and during the occupation the civilians suffered tremendously. Mao also used the Joseon kingdom, Ming's ally, as a base to launch expeditions against the Jurchens. When the Jurchens entered Joseon, Mao ordered a general retreat of Ming forces. This angered many merchants in the Beijing area who traded in the Korean Peninsula. In addition, Mao was known to have bribed many corrupt eunuchs and officials. Consequently, by executing Mao, Yuan made enemies with some of the most influential people in China. Taking advantage of Nurhaci's death later in the year, Yuan reoccupied Jinzhou. The Jurchens reappeared in June and withdrew after a series of indecisive battles. Yuan was criticised by the partisans of Wei Zhongxian, who stated that he took too long to fight off the Jurchens. Shortly thereafter Yuan was forced into retirement. Later military career and death In 1628, under the reign of the Chongzhen Emperor, Yuan was reinstated as the field marshal of all the Ming forces in the northeast. He embarked on an