Imagine making a thrilling, career-topping discovery. Then imagine the resulting glow being snuffed out by a grueling, yearslong legal battle.

That is the tale told in “Dinosaur 13,” a documentary by Todd Douglas Miller being broadcast Thursday night on CNN. The title refers to the 13th Tyrannosaurus rex skeleton ever found, the most complete such skeleton yet discovered. Susan Hendrickson located the first fragments in 1990 in South Dakota while working with the paleontologist Peter Larson. The film recounts the team’s exhilaration and how it soon dissipated as legal challenges to the find accumulated, from the federal government and other quarters.

The disputes dragged on for years and raised difficult questions about ownership of historic discoveries, though the film doesn’t always explore them thoroughly. It is an enthralling tale nonetheless. “Dinosaur 13 may not be the best documentary,” Jeannette Catsoulis wrote in reviewing the film for The New York Times when it had a theatrical release in August, “but as a scientific soap opera, it’s a doozy.”