Captain Moroni had consulted Alma. The Prophet told Moroni what the Lord had revealed to him about what was going to happen. The Lord would not have revealed it, if he did not expect Moroni to follow through. Moroni and his men now knew that God was on his side, and this must have been of great comfort to the Nephites, who were underdogs in this conflict. They likely did not have as many soldiers under arms as their opponents. They succeeded partially because of the terrain; they knew the value of the high ground. When you have the higher ground, and you can attack people who are slowed as they are wading through a river or coming up out of the valley. There you can inflict a lot of damage. So it worked for the Nephites. They were much better prepared, and events proceed in their favor in this particular war.