[Warning: This article contains minor spoilers for Ant-Man]

-

Earlier this summer a licensing agreement between Marvel Studios and Sony Pictures regarding the portrayal of Spider-Man leaked onto the internet, causing a small amount of buzz. The contract stipulated that Peter Parker had to be Caucasian, heterosexual, middle class and male, that he had to design his own costume, and - most importantly - that he couldn't kill unless in self-defense and was not allowed to smoke, abuse alcohol, have underage sex or become a drug dealer. Thus died the weird, gritty, R-rated interpretation of Spider-Man that might have been.

Such stipulations are common when one company licenses the rights to a character from another company, and Marvel found itself on the other side of the fence when beloved children's book and TV character Thomas the Tank Engine was written into the climactic fight scene of Ant-Man. In a clip that was heavily featured in the trailers, the villainous Yellowjacket lands on the tracks of a children's train set (in his miniaturized form) and is hit by an enormous Thomas with great, terrible ever-rolling eyes.

Speaking in an interview with Film School Rejects, Ant-Man director Peyton Reed offered some insights into how the Thomas the Tank Engine scene came about, and some of the contractual limitations put in place by the rights-holder, Mattel.

"I believe in Edgar [Wright] and Joe Cornish’s original drafts it was a train set. At some point in the process that predated my involvement it became Thomas. As I came on, they had not secured the rights to Thomas. We had to do this whole thing where we did this presentation for the people who own the rights to Thomas. Thank God they agreed and found it funny, but there were definite stipulations. For example, nobody could be tied to the tracks and run over by Thomas. Thomas couldn't be doing anything that could be perceived by children as evil Thomas. Thomas had to stay neutral in the battle, which was always our intention.

"Like anybody, they’re protective of their brand. I didn’t know what we were going to do if we didn’t get the rights to that. There are certain things I was going to be devastated about if we couldn't have them. Thomas was one, because...you could do any kind of toy train, but the personality of that thing and the eyes moving back and forth give it a whole vibe and took it to another level."

Reed's presentation paid off. Thomas the Tank Engine's shining moment is one of the most memorable gags in Ant-Man, and the train goes on to play an even bigger role in the movie than the trailers indicate.

Ant-Man train scene

Reed also discussed another joke in Ant-Man that required permission to use licensed property - in this case The Cure's album Disintegration and the first song off that album, "Plainsong." The song comes into play during another Ant-Man/Yellowjacket fight scene and is part of a joke about the iPhone's voice recognition software.

"In the briefcase battle, we knew we wanted to have an iPhone joke. We had all these different versions of jokes, like, Yellowjacket saying, ‘You’re going to end up dead!’ and then you’d hear ‘Searching for the nearest Panera Bread.’ There were some funny jokes and some not-so-funny jokes, but, at the end of the day, they were just jokes. What if he activated the music feature? What would it be? I'm a massive Cure fan. We came up with a bunch of things, but we thought we could find a joke for ‘disintegration.’

"The first song on Disintegration, which is the second CD I ever bought, was ‘Plainsong’. It’s such an epic song that it transcended the joke — scoring this whole battle in a briefcase. There was this weird, cold wave goth vibe, changing the character of that action scene. You have all these action scenes you want to have a different flavor. Then it became a question of, ‘Will [The Cure frontman] Robert Smith let us use his music?’ He ended up loving it, so he did."

These two anecdotes are simply smaller insights into the scope and complexities of licensing rights for movies, which involves getting permission for every logo or copyrighted property that appears on screen, as well as every song on the soundtrack. The most important thing to take away from this, however, is that Thomas the Tank Engine is not, and never will be, evil.

Ant-Man is now playing in theaters; Captain America: Civil War arrives on May 6, 2016; Doctor Strange – November 4, 2016; Guardians of the Galaxy Vol. 2 – May 5, 2017; Spider-Man reboot – July 28, 2017; Thor: Ragnarok – November 3, 2017; Avengers: Infinity War Part 1 – May 4, 2018; Black Panther – July 6, 2018; Captain Marvel – November 2, 2018; Avengers: Infinity War Part 2 – May 3, 2019; Inhumans – July 12, 2019.

Source: Film School Rejects (via ComicBook.com)