Seventeen years after the beginning of The Dark Knight franchise, Gary Oldman’s iconic role of Jim Gordon is still among his best and most remembered. As Gotham City’s police commissioner and Batman’s right-hand man, Jim Gordon’s character was portrayed by Oldman in all of the films from Christopher Nolan’s Dark Knight trilogy, including Batman Begins, The Dark Knight, and The Dark Knight Rises. Though it is hard to imagine him in any other role now, Oldman almost played a very different character in The Dark Knight movies due to his history of being typecast as a villain.

With origins stemming from the comics, Jim Gordon’s story in Batman is one that has been told many times. In Batman Begins, Gordon is on duty the night Bruce Wayne’s parents are killed and comforts young Bruce, laying the foundation for their coming friendship. Even before Bruce becomes Batman, he thinks of Jim Gordon as one of Gotham’s only honest cops and identifies Gordon’s virtuous nature.

Related: The Batman's Riddler vs. Dark Knight's Joker: Who Is The Better Villain?

Their relationship and mutual respect maintain throughout the following films, The Dark Knight and The Dark Knight Rises, with Jim Gordon, in many ways, as much a hero as Batman himself. Oldman, however, was not always intended to play Gordon. Originally, he was cast as the chemical-wielding, bag-masked villain, Scarecrow (later played by Cillian Murphy).

Cillian Murphy as Scarecrow wearing his mask in Batman Begins

Dubbed “Scary Gary” by Harrison Ford after a long history of playing bad guys, Gary Oldman spent much of his career typecast as a villain. In an interview (via BBC Radio 1), Oldman says, I think that the villain thing really came out of the work I had done with Besson.” He is referring to director Luc Besson, with which Oldman filmed several of his early successful movies like 1994’s Léon: The Professional, and 1997’s back-to-back films Nil by Mouth and The Fifth Element. However, even before working with Besson, Oldman had played notorious villains like Lee Harvey Oswald in JFK, Dracula in Bram Stoker’s Dracula, and Drexl Spivey in the Tarantino-written True Romance.

It was not until producer Douglas Urbanski (whose career with Oldman began with Wildly Available in 1996) suggested the recast to Nolan that Oldman stepped into the role of The Dark Knight trilogy’s Jim Gordon. Reflecting on the role in his interview, Oldman describes Gordon as “incorruptible” and “straight as an arrow,” qualities that the actor claims made the role of Gordon “quite challenging.” Oldman goes on to say, “It's that thing of turning up, and Batman's already got there first. You're a detective, but you don't really get a chance to do any detecting because Batman's done it all for you." Yet, despite the futility Oldman speaks of, Jim Gordon’s impact on Bruce Wayne and, later, Batman is an essential part of the hero’s character, with Gordon being everything Batman stands for and Batman, everything Gordon hopes for.

More: Nolan's Dark Knight Trilogy Used A Clever Genre Trick To Make Batman Work

Key Release Dates