The Ammonites marched out and formed a battle line at the entrance to the city, while the kings who had come remained in the countryside.