While Life may sometimes seem like a loving collaboration of used parts  —  a dash of Alien, a dollop of Gravity, a pinch of every ’90s monster movie your parents still have on VHS in their attic  —  there is one element of the movie that is Life and Life’s alone: that ending. If you haven’t seen the film yet, now would be a good time to stop reading, because we’re going to get into the nuts and bolts of what made that Life ending work.

As you’ll remember  —  or as you’ll now learn, if you just don’t care about the film and like being spoiled  —  Life ends with Jake Gyllenhaal and Rebecca Ferguson’s characters blasting off in separate escape pods. Gyllenhaal’s David, who has trapped the alien in his own escape pod, is supposed to be headed towards deep space, but the movie has different ending in mind. When the pod doors open on the planet below, we discover that David and the creature have landed on Earth while Ferguson’s Miranda has been sent spinning off into the cosmos. It’s a shockingly bleak ending for a pretty mainstream movie.

And according to director Daniel Espinosa, that was the only ending he would have accepted. In an interview with The Hollywood Reporter, Espinosa explained why he would rather have walked away from the project than change the film’s twist ending:

When I met the producers, I told them, “I completely understand that this ending might not be the preferable choice, but for me it was a fundamental part of the reason I want to do the movie.” If we couldn’t see eye to eye with the ending, we should part ways before we get something started. My producers were completely supportive, which I thought was surprising and bold.

Even if you were only lukewarm on Life, the film is the rare entry on the list of movies where the bad guy wins. Most of those films act as twisty little pieces of neo-noir   — movies like Arlington Road and The Usual Suspects come immediately to mind  —  but it’s rare for us to see a movie with an A-list cast and a prime pseudo-summer release spot end on such a dour note. With all the talk about R-ratings and mature content for our summer movies, fingers crossed that the lesson Sony learns from Life is that some movies need to have unhappy endings.

Here’s the full plot synopsis for Life:

Life tells the story of the six-member crew of the International Space Station that is on the cutting edge of one of the most important discoveries in human history: the first evidence of extraterrestrial life on Mars. As the crew begins to conduct research, their methods end up having unintended consequences and the life form proves more intelligent than anyone ever expected.

Life also stars Ryan Reynolds, Hiroyuki Sanada, and Ariyon Bakare and is now playing in theaters everywhere.

More From ScreenCrush