Ancient People Were Deeply Religious
Ancient peoples were deeply religious. In the Bronze Age, for example, Hittite and Egyptian accounts regularly give the gods a role in military campaigns. No Hittite scribe would think of recording a victory without thanking the gods for having marched in front of the army and thereby having granted the king success. No ambassador would swear to abide by a treaty unless an assembly of the various gods had witnessed it. In his poem about the battle of Qadesh (1274 [B.C.E.]), Pharaoh Rameses II declares that the god Amun spoke to him and sent him forward.
Even in the rationalistic heyday of classical Greece—and later—gods and heroes were commonly seen in the heat of battle. Sometimes their mere presence provided encouragement to the soldiers. At other times, divinities gave specific military advice. And sometimes they even fought! At the decisive battles of Marathon (490 [B.C.E.]), Salamis (480 [B.C.E.]), Aegospotami (405 [B.C.E.]), and Leuctra (371 [B.C.E.]), for example, contemporaries thought the gods and heroes took part.
— Barry Strauss, The Trojan War, pp. 74-75