During the Battles of Yongqiu and Suiyang, the Tang soldiers in Yongqiu were running out of arrows. Zhang Xun ordered about 1,000 scarecrows to be made. At night, soldiers put their own armor onto the scarecrows, and hung them down from the Castle walls. Yan forces saw this and shot many arrows at the scarecrows, since they thought they were Tang soldiers. By the time the Yan forces found out what happened, the Tang troops had already received about 200,000 arrows. When this happened again later, Yan soldiers did not shoot one single arrow at them. But these dark figures were real Tang soldiers, who quickly attacked the sleeping Yan ranks. The vast Yan forces were forced to retreat from their position.