Want the latest climate news in your inbox? You can sign up here to receive Climate Fwd:, our email newsletter.

More than 3,000 years ago the queen of the Hittites, who lived in what is now Turkey, sent a clay tablet to Ramses II, the Egyptian pharaoh, with an S O S: “I have no grain in my lands.”

Previously, the two kingdoms had been at war. Now a severe drought was carving a path of destruction through the ancient Levant, killing crops, cattle and people.

But the Egyptians, unlike the Hittites, had anticipated a crisis and planned ahead for a food shortage, researchers at Tel Aviv University say. And in an attempt to stabilize their borders, the pharoahs appear to have mounted a relief effort, sending grain to their former enemies.

In a study published in this year’s edition of the journal Egypt and the Levant, the researchers pieced together ancient evidence — including flint and bone records from the fallen city of Megiddo, fossilized pollen data from the Sea of Galilee and ancient cattle DNA — to shed light on how Bronze Age Egyptians used careful planning and policies to adapt to a drought that lasted from around 1250 B.C. to 1100 B.C., while their ancient counterparts appeared to be less well prepared.