At the beginning of the battle, you'll be in the central area of Wuzhang and you will need to defeat the encroaching Shu officers. As you're fighting them, some more officers will start making their way towards Wei's main camp, so take them out, too. You'll be told to start heading towards Shu's main camp, but as you do, their officers will begin to retreat.
You'll have to give chase to the Shu officers via the central garrison, but as you get close to it, the gates will close and Guan Suo will appear. Defeat him to open all of the gates. At the next base, Guan Yinping will appear and drop into the base, so defeat her and continue. Note that Wei Yan and Ma Dai will appear on a separate path than the one you're probably using.
When you enter the main camp, Jiang Wei will set fire to it, retreat and some Juggernauts will spawn. Destroy them and the gates will be open, with Jiang Wei reappearing in the southeast garrison. As you continue along the path to where Jiang Wei is located, Yueying will appear, along with some arbalests.
After defeating her and the arbalests, you'll find Zhao Yun appearing along the path. Defeat him and continue to the southeast garrison, where you'll find Jiang Wei. His defeat will bring an end to the battle.