An asteroid that hit Earth millions of years ago and is believed to have been responsible for driving dinosaurs to extinction could not have come at a worse time in the evolution of the prehistoric vertebrates, which dominated Earth for 135 million years, according to a new study.

Dinosaurs are believed to have ruled the planet from the beginning of the Jurassic period about 201 million years ago until the end of the Cretaceous period some 66 million years ago, when a massive asteroid impact, led to the extinction of most dinosaur groups on Earth. Now, a new study, published in the journal Biological Reviews, on Monday, has concluded that dinosaurs might have survived the killer asteroid strike if it had occurred slightly earlier or later in the planet's evolutionary history.

“The dinosaurs were victims of colossal bad luck,” Stephen Brusatte, a paleontologist at the University of Edinburgh, said in a statement. “Not only did a giant asteroid strike, but it happened at the worst possible time, when their ecosystems were vulnerable. Our new findings help clarify one of the enduring mysteries of science.”

Scientists used up-to-date fossil records and improved analytical tools to find that, in the few million years prior to the asteroid impact that created the Yucatan's Chicxulub crater in Mexico, Earth was experiencing a major transformation in its environment, including widespread volcanic activity, changing sea levels and varying temperatures.

According to scientists, changes to the planet's climate and environment resulted in a lack of diversity among large plant-eating dinosaurs, which ultimately also hurt carnivorous predators of the time by weakening the food chain. All these changes made the dinosaurs vulnerable and unlikely to survive the aftermath of the asteroid strike, which might have possibly caused tsunamis, earthquakes, wildfires, unexpected temperature swings and other environmental changes. As a result, the dinosaurs’ food chains collapsed, leading to their extinction, except the ones that could fly, who gradually evolved into modern-day birds.

The researchers suggest in the new study that if the asteroid had struck a few million years earlier, when the range of dinosaur species was more diverse with healthier food chains, or later, when new species had had time to evolve, they may have survived the asteroid hit.

"Although our research suggests that dinosaur communities were particularly vulnerable at the time the asteroid hit, there is nothing to suggest that dinosaurs were doomed to extinction,” Richard Butler of the University of Birmingham, said in the statement. “Without that asteroid, the dinosaurs would probably still be here, and we very probably would not.”