Numbers 22:21-29 (New King James Version)
Balaam got up in the morning, saddled his ass and went with the princes of Moab.
But God was very angry when he went, and the angel of the LORD stood in the road to oppose him.
Balaam was riding on his ass, and his two servants were with him.
When his ass saw the angel of the LORD standing in the road with a drawn sword in his hand,
his ass turned off the road into a field.
Balaam beat his ass to get his ass back on the road.
Then the angel of the LORD stood in a narrow path between two vineyards, with walls on both sides.
When his ass saw the angel of the LORD, his ass pressed close to the wall, crushing Balaam's foot against it.
So he beat his ass again.
Then the angel of the LORD moved on ahead and stood in a narrow place where there was no room to turn, either to the right or to the left.
When his ass saw the angel of the LORD, his ass lay down under Balaam, and he was angry
and beat his ass with his staff.
Then the LORD opened his ass's mouth,
and his ass said to Balaam, "What have I done to you to make you beat me these three times?"
Balaam answered his ass, "You have made a fool of me! If I had a sword in my hand, I would kill you right now."