When it comes to diet, foxes are the teenagers of the animal kingdom. They’re opportunistic predators, meaning they’ll eat whatever they can find.

In the Middle Paleolithic, that meant small game like rodents or rabbits and the occasional fruit, vegetable, bird or worm. But foxes’ diets changed drastically once ancient Homo sapiens arrived on scene. About 42,000 years ago, the foxes in southwest Germany ate reindeer meat leftovers from nearby humans, a German team from the University of Tübingen reports in PLOS ONE. The findings illustrate how humans have been shaping the environment around us for thousands of years, the researchers write.

“Early modern humans had an influence on the local ecosystem as early as 40,000 years ago,” the authors said in a press release. “The more humans populated a particular region, the more the foxes adapted to them.”

Neanderthals, an extinct species of early humans, lived in southwestern Germany in the Middle Paleolithic, more than 42,000 years ago. Neanderthals in this area lived in small, nomadic groups that moved around frequently, possibly to hunt or find caves to escape the cold. The region was sparsely populated until the Upper Paleolithic period, when anatomically modern humans, or Homo sapiens, moved in. The number of early humans living in southwestern Germany jumped drastically during the Upper Paleolithic. H. sapiens quickly outnumbered the Neanderthals, who went extinct around 40,000 years ago. The new study suggests that this shift from Neanderthal to H. sapiens changed the diets of foxes living in the area, as opportunistic foxes adapted to the humans around them.

The team analyzed the chemical composition in the collagen within fox bones from both the Middle and Upper Paleolithic to figure out what the foxes ate thousands of years ago. The amount and types of Carbon and Nitrogen in collagen correspond with the animal’s diet. For example, it tells scientists what that animal’s main protein sources were in the last few years of its life.

Overall, they found that foxes living in the Middle Paleolithic, at the same time as Neanderthals, ate typical fox things like rodents and other small animals. But as Neanderthals died out and Homo sapiens dominated the landscape in the Upper Paleolithic, foxes ate more and more reindeer. To the researchers, that meant the foxes must have been stealing leftover reindeer meat from early Homo sapiens’ camp sites. Reindeer are too large for foxes to hunt, but an ancient human certainly could. In fact, ancient humans during this period often hunted reindeer and horses for food, dragging the carcasses back to the cave dwelling and butchering it there.

Foxes capitalized on this new source of food, and they’ve been stealing humans’ leftovers ever since. In fact, several recent studies have shown that foxes living near towns or cities have different diets than foxes living in the wilderness. The closer foxes live to humans, the more they eat our leftover food instead of hunting prey. Foxes that live far away from humans often revert back eating small game.

“That humans are at least partly responsible for the extinction of the Ice Age megafauna is quite certain from a scientific point of view,” Baumann told CNN in an email. “That our ancestors also had an influence on other animals so familiar to us today, and that they even benefited from the presence and ecological impact of humans, is new.”

But the fox study is just one example of how humans have impacted the environment today and thousands of years ago. As soon as we began killing large plant-eating animals, humans started a cascade that ultimately led to climate change, the authors write in their paper.