It makes a wicked kind of sense that it took a mad scientist to transform Fox's Gotham into the show it was always meant to be. And that new form is on ample display in the confident, often hilarious, and finally even-keeled Season 3 premiere (Sept. 19, 8/7c).

Mild spoilers for the premiere past this point.

When we last left the citizens of the pre-Batman metropolis Gotham City, a host of monsters had been released from the labs of Dr. Hugo Strange (BD Wong), the aforementioned mad scientist who experimented on the insane inmates of Arkham Asylum to create insane animal/human hybrids. Those hybrids — including returning villain Fish Mooney (Jada Pinkett Smith) — are laying siege to Gotham, and only a host of heroes, and a handful of villains, stand in their way.

Gotham's second season found its way by losing its mind

But let's take it even further back. The first season of Gotham was the definition of a mixed bag, awkwardly mixing tones from throughout the Batman mythos. Was it a high-minded crime tragedy, a la Christopher Nolan's Dark Knight trilogy? Was it gothic dark humor, like in Tim Burton's movies? Or high camp, straight from the Adam West series?

From scene to scene, the first season of Gotham veered from one to the other, but it never jelled. The actors were game, the stunts and set pieces were often fun... but it felt like a show at war with itself. Nowhere was this more prominent than with Pinkett-Smith's Mooney, a light Eartha Kitt impersonation that seemed to exist on a different planet entirely.

Season 2 ditched the Nolan, and Pinkett-Smith's character, and went full-on bananas Burton. Members of the Gotham Police Department were besieged and murdered on a weekly basis as showrunner Bruno Heller & Co. literally culled the elements that were holding the show back. And more importantly, over two half-season arcs, the villains were finally allowed to be villainous.

Did it make sense that Mr. Freeze, The Penguin, Firefly, and even an early form of The Joker appeared in a Batman origin story, when Batman was still barely a teenager? Nope. But it was more fun to watch, and by breaking with the timeline created by the comic books, Gotham delivered a show that felt surprisingly new week after week.

Fall TV Preview: Where we left off with Gotham and other returning shows

But one thing it never quite got around to was establishing the absolute madness of living in Gotham City. The city's name is the title of the show, but for the most part Gotham was either the story of hero cop James Gordon (Ben McKenzie) grappling with the moral complexities of the city's criminal elements (and occasionally its cops) testing his character; or Bruce Wayne (David Mazouz) slowly unraveling the conspiracy behind his parents' murder.

What the show (and writers) realized in Season 2 is that these characters are stronger when they're presented together as a group, rather than running on their own separate trains, or taking a backseat to the show's ostensible stars. That's exactly where we pick up in Season 3, with a city that feels inhabited, with a populace of maniacs and morally gray lawmen living at war, and sometimes in an uneasy truce. It's not The Gordon Show anymore; it's an ensemble. And Bruce has finally had enough training that he can (mostly) hold his own against Gotham's more nefarious elements.

That transformation has happened because the show has finally established the former side characters as worthy of their own storylines: Standout villainess Barbara Kean (Erin Richards) owns the premiere with her manic, unhinged energy, and sad sack henchmen Butch (Drew Powell) is a character free of comic continuity whose deadpan comedy lights up his scenes. Even Mooney makes sense in this new world. If you want to get philosophical about it, maybe Pinkett-Smith inherently knew what the show had to become, and just bided her time until everyone else came around.

Gotham: Bruce's new "Playboy" persona isn't what you think

The other actors have come around in spades. After Gordon lost his girlfriend last season, and went rogue from the GCPD, McKenzie finally gets to play him less straight-laced, and more Ryan Atwood (a.k.a. fun). Edward Nygma (Cory Michael-Smith) was also transformed into The Riddler in all but name last season, and though he only gets one scene with The Penguin (Robin Lord Taylor) in the premiere, it shows off why this pairing was one of the most fun combos of characters last season.

It goes almost without saying, by the way, that Lord Taylor continues to be the true star of Gotham, a fact that was clear from the very first episode. Even three seasons in, his Oswald Cobblepot is a sputtering, twitchy mess who still manages to swing from menace to friendliness in a single scene. His reintroduction towards the start of the premiere is the hour's first applause-worthy moment, and it's followed up by a signature greeting ("Hello, Jim") that balances absolute horror, joy, and probably about 30 other emotions at the same time in two simple words.

Even Selina Kyle (Camren Bicondova) gets more to do than just hang around on rooftops, instead slinking everywhere and changing her loyalties at a whim — you know, like a cat. Because she's Catwoman. And as usual, Alfred (Sean Pertwee) gets the best lines and action, now that we've settled into the premise that he's not just serving tea, but also serving up smackdowns.

If there's one aspect that holds back the premiere, it's that the plot is a pretty smooth continuation from Season 2. Where last year's premiere was a soft reboot, this year Gotham knows what it is: a double-edged sword that's great for returning viewers, but may be a stumbling block for new ones.

Regardless, Gotham is finally a show about a city and the people who live in it, not just a Batman origin story biding time until young Bruce Wayne puts on his costume. And, just as our group of misfits has it all figured out — in the premiere, everyone seems resigned to yet another monster attack, and even know each other so well that sequences become a series of intellectual chess matches interrupted by crazy violence — enter a new villain, who comic readers know is the spirit of order and control in Gotham City fighting back. A perfect foil for the beautiful disorder Gotham has become.

This transformation couldn't have happened without the arch insanity Strange brought to the show. And with a Bruce Wayne doppelgänger on the loose, a gang of monsters running amok, a police department that has pretty much given up, and new/old villains more powerful than we've ever seen before, the stage is set for a season that will transform Gotham — the city, and the show — one more time.

Gotham's third season premieres on Fox on Monday, September 19 at 8/7c.