Spoilers for Gotham “Ace Chemicals” past this point.

When FOX’s Batman origin story Gotham kicked off five years ago, the cast was almost incessantly asked (often by me, sorry guys) when and if The Joker would show up. The other villains were present in their nascent forms, from The Riddler (Cory Michael Smith) to Catwoman (Camren Bicondova). But the clown prince of crime was nowhere to be seen. Then, we met Jerome Valeska (Cameron Monaghan), a giggling, amoral murderer who clearly was the model for The Joker… Except he died, a bunch. And then he was replaced by his twin brother Jeremiah Valeska (also Monaghan), who also died a bunch. Along the way we got teases and taunts and proto-Jokers… Until now, when the show has finally looped to The Joker’s classic comic book origin, and with it the series’s smartest riff on Batman lore, ever.

Bold pronouncement, I know, given Gotham has been tweaking Batman’s origin for years now. But what Gotham has done while creating its own continuity is that it’s mostly ignored the weird, metatextual nature of comics themselves; that with decades of stories behind them, ultimately things aren’t going to make a lot of sense when you look at it as one, long narrative.

That’s what “Ace Chemicals” dealt with head on, and impressively so. In the books, The Joker’s origin has never been clearly defined. In Alan Moore and Brian Bolland’s “The Killing Joke,” that’s the crux of the tale — or rather, tales, as we get to see The Joker’s “origin” story told multiple times, and the audience can decide whether any of those stories are true. This was smartly touched on with the “want to know how I got these scars?” moments in The Dark Knight; “Ace Chemicals” comes at this a different way.

In the episode, Jeremiah has launched an ambitious plan to insert himself into Bruce Wayne’s (David Mazouz) origin by making him relive the fateful day his parents died. He’s given two random people plastic surgery to look like Thomas and Martha Wayne. He’s recreated The Mark of Zorro, the movie the Waynes went to see before they died. He’s got everything on lock, down to the sandwiches they ate before leaving for the theater. Bruce, of course, pursues him, and that’s when Jeremiah reveals his big twist: since he knows killing two random people won’t have the same emotional impact, he’s used the Mad Hatter (Benedict Samuels) to hypnotize Bruce’s de facto new Mom and Dad, Jim Gordon (Ben McKenzie) and Lee Thompkins (Morena Baccarin), and will kill them instead.

Bruce stops him — or rather, after admitting that she stood by and did nothing while his real parents died a few episodes back, Selina (Bicondova) whips Jeremiah, breaking the hypnotic spell and allowing Bruce to pursue him into the Ace Chemicals factory. There, they fight and Jeremiah plunges into a vat of chemicals. He survives, but is horrifically burned all over his body.

In various iterations (including Tim Burton’s 1989 Batman) that’s how The Joker got his pale tinge, but it isn’t the bit I want to talk about. No, that’s in the alley, where Gotham comes to grips with 80 years of Batman history. Ask anyone who killed the Waynes, and you’ll get conflicting answers: it was a random thug; it was a guy named Joe Chill; it was The Joker; Batman has no idea who did it. Thing is, all of those answers are true, or have been true and various points in the past eight decades. On Gotham, we’ve learned that a random thug killed the Wayne parents, though he was ordered to do it by the Court of Owls, an organization that controls most of Gotham City. And they were run by Ra’s al Ghul (Alexander Siddig), who wanted to create an event that would eventually lead to Bruce Wayne turning into Batman.

By having Jeremiah lament his lack of inclusion in the story, he’s essentially commenting on the text of Gotham itself. The Joker is such a part of Batman, and he of it; to create this narrative he’s attempting to reroute the path of the show to one more traditionally known by the casual Batman fan. He’s not successful, of course; but for that moment in the alley his speech underlines how the dueling origins of The Joker established in Gotham make as little sense when you pick at them as the dueling origins of Batman. And that’s okay! It’s a little crazy (just like the show), but everything can be true about these iconic characters, all at the same time.

Is Jeremiah actually The Joker? Who really killed the Waynes? These are key questions in the mythos that return, time and again, each time with a different answer. And that’s okay. The beauty of stories like this is they can change with the times. Gotham has one narrative, one serialized path. But for a brief moment in that alley, you can imagine it all diverged in a million different directions. Therein lies the joke. Pretty funny, right?

Gotham airs Thursdays at 8/7c on FOX.

Where to stream Gotham