According to James McAvoy, X-Men: Dark Phoenix underwent lengthy reshoots to change the film’s ending after it was discovered that it bore a striking resemblance to another superhero film that was also in production.

The latest X-Men film, in cinemas 5 June, originally wrapped production in October 2017. It was extensively retooled during reshoots over a year later in August-September 2018, pushing the film’s release date back first from March 2018 to February 2019, then later to June this year.

The official line from everyone around the shoot is that the film’s ending - originally set in space - was changed to an earthbound sequence to give the finale a more grounded feel.

Read more: Did Endgame introduce the X-Men to the MCU?

However, James McAvoy, who plays a conflicted Charles Xavier in Dark Phoenix, says there’s more to it than that. Talking about the reshoots, McAvoy admits to Yahoo Movies UK: “The end [of Dark Phoenix] changed a hell of a lot.”

“The finale HAD to change. There was a lot of overlap and parallels with another superhero movie that came out... a while ago. And we had no idea that we were...”

“They had spies on set,” interjects co-star Michael Fassbender, returning for a fourth time as Erik “Magneto” Lensherr, “and [they] basically stole our ideas.”

“We were basically trawling through the source material it seems,” finishes McAvoy.

Michael Fassbender and James McAvoy spill the beans on those Dark Phoenix reshoots. More

The duo wouldn’t be drawn on which rival superhero movie they were referring to, leaving it wide open to speculation.

Looking at the release schedule from Dark Phoenix’s wrap date in October 2017 to now, there have been 11 major live action DC or Marvel superhero movies in cinemas during that period: Thor: Ragnarok, Justice League, Black Panther, Avengers: Infinity War, Deadpool 2, Ant-Man and the Wasp, Venom, Aquaman, Captain Marvel, Shazam!, and Avengers: Endgame.

Of those films, only Thor: Ragnarok, Infinity War, Captain Marvel, and Endgame have had lengthy space-set sequences that could potentially clash with Dark Phoenix’s original climax. Interestingly, Disney’s acquisition of Fox - the studio behind Dark Phoenix - was first reported in November 2017, during the post-production phase on the new X-Men film.

The planned merger might have led to a “show and tell” meeting, with execs at the two rival superhero studios at Fox and Disney (Marvel Studios) looking over each other’s upcoming slates to ensure there were no clashes between their films. But which Marvel Studios film specifically might have been trawling “through the same source material”? We think there are two likely contenders.

Simon Kinberg, director of Dark Phoenix, previously stated they’d also changed the VFX around Jean Grey’s (Sophie Turner) transformation into Dark Phoenix to make it more “cosmic” and less “flamy”.

Flame on: Early Dark Phoenix publicity stills showed a much more fiery look for Jean Grey. This has been changed in the final film for something very different. (20th Century Fox/Marvel Studios) More

Story continues