On Christmas Eve, a new criminal known as the Joker, at the time disguised as the criminal kingpin, Black Mask, after he tortured Warden Martin Joseph, and threatened his family, forced the warden to make security lax in order to engineer a prison riot inside Blackgate. After Black Mask and several of his men, including Killer Croc, broke into Blackgate, a dispatch was issued that requested backup as Commissioner Gillian B. Loeb and the news crew were taken hostage. Bruce Wayne, who overheard that dispatch, donned his identity of Batman and went to Blackgate to quell the riot, but was too late to save Loeb.
After the Joker was exposed as Black Mask and incarcerated at Blackgate, the Joker, while he underwent a psychiatric evaluation by Intern, Harleen Quinzel, managed to seduce and manipulate her to have an insider inside the prison. Harleen then slipped Joker some security codes, which he used to escape his cell and instigated a particularly destructive riot and released all of the prisoners except for Deathstroke, as the latter didn't want his time wasted especially when his attempt at collecting the bounty on Batman turned out to be such. That resulted in the staff sending a dispatch that requested assistance, which Batman managed to barely respond to due to depression for nearly letting Alfred die at the hands of Bane, who broke into the Batcave, caused a lot of destruction, and trapped Alfred underneath the under-construction Batmobile.
Upon arrival, Batman found several prisoners holding a trio of guards hostage and debating whether to kill them immediately or otherwise exact revenge on them. Batman then beat up the would-be escapees, and informed the guards to get the gates open for Captain James Gordon and the GCPD. Batman then accessed the main sewer system and destroyed a weak foundation on the floor with Explosive Gel. He then found the water in one part of the sewer system electrified alongside several dead bodies. After he shut off the electric box, Batman then scaled the sewer system and burst several pipes in order to continue forward. After he escaped the sewer system, Batman found several prisoners who almost made it out and beat them into submission. Batman then continued onward just as Joker requested that everyone search for Batman and bring him to him alive. Batman then arrived at the Nexus where 2 guards and Harleen were held hostage. After Batman rescued them, Harleen pointed him towards Joker's location at the Panopticon, and that he was waiting for him. Batman then traversed through the prison searching out the Panopticon and also dealt with more prisoners who attacked him in various cell blocks.
After Batman entered the Panopticon, Joker revealed he had Warden Joseph hostage, and gave Bane a heart monitor that would charge a battery for the prison facility's electric chair, which would electrocute the Joker to death unless Batman broke his one rule and killed Bane. Batman refused, but Bane informed him that someone would die, and that he had better fight with all of his resolve. Batman then reluctantly fought Bane. Joker also told the two that he'd have the prison explode via a placed explosive that was set to go off if either of them removed the heart monitor, which anticipated that likelihood. Batman was easily taken down by Bane, who did a back breaker on Batman and crushed him underfoot. Gordon and the GCPD then arrived in the nick of time, shot Joker's Henchmen, and saved Joseph. Gordon then tried to get Joker out of the electric chair when he discovered that the psychopathic clown had gotten himself into, but ended up being held hostage by him instead and had his life put in peril. Batman then decided, after he remembered one of the Electrocutioner's earlier taunts and to a lesser extent someone using a defilbrator on a downed police officer during a small scale riot at the GCPD, that he temporarily stop Bane's heart long enough to fool the Joker into thinking that he killed him. After Batman used the Shock Gloves and put Bane into Cardiopulminory Arrest, Joker, after he got free, threatened to shoot Joseph when he stood up to him, only for Gordon to take the bullet (he only survived due to his bulletproof vest), with Joker then announced that he's going to set off the explosives that he set throughout Gotham earlier and took Gordon's gun. Batman then told Gordon and Joseph to go after the Joker and explained that he needed to revive Bane before it was too late, as he didn't kill criminals. Bane, after his heart was restarted, then grabbed Batman, and declared that he had no other option but to inject himself with TN-1 to stop him. Batman then detonated the floor that they were on with Explosive Gel, which dropped them in a Prison Corridor below.
Batman then had to stop Bane within ten minutes after he learned more from Alfred about TN-1. After he barely electrocuted Bane long enough to temporarily stun him, Batman told Alfred that he had defeated Bane, only to be grabbed and thrown into a wall by Bane. During that time, all of the exits were sealed. Batman then restrained Bane to several electrodes with the Remote Claw, and hung him upside down, with Bane unable to remember Batman's connection to Bruce Wayne due to the side effects of TN-1. Batman then went to Death Row, where Joseph was wounded by one of the Joker's Snipers, with Gordon requesting a medical evacuation immediately. Croc then tried to ambush Batman, but was instead grazed by a stray sniper round due to Gordon, in anger at the sniper for harming the warden, interfered with his shot. Batman and Gordon then worked together and fought off several of Joker's Henchmen. Gordon then stayed put while Batman pursued Joker to the Prison Chapel (he learned that from Gordon).
Batman then fought the Joker at the Prison Chapel, the Joker was irate with Batman after he learned that Batman didn't actually kill Bane. Joker eventually attempted to slit Batman's throat with broken glass shards after Batman threw him at a stained glass window while he ranted that both Batman and himself existed because of "them." After he sustained an extensive Beatdown, Joker believed that Batman loved to beat people up and requested that Batman brutally kill him. However, after Joker was briefly strangled by Batman, Batman came to his senses and knocked him out just as Gordon came in, with Gordon admitting that had he or his other guys been in his situation, he would have killed him. After a brief exchange of words and returning Gordon's gun, Gordon tried to bring Batman under arrest, since although he did good in stopping the riot, he still technically broke the law. However, Gordon let Batman escape when Harvey Bullock contacted him.
Joker was returned to his cell, although not without him deciding that his future encounters with Batman would be "fun." Bane was also placed into incarceration for his role in the riots. Gordon then told Barbara that she was the main reason why he let Batman escape, as well as Batman might be the one to bring about hope for a less corrupt police force and law system. It was because of the events of that riot that Arkham Asylum was reopened at the request of political activist, Quincy Sharp. The riots also resulted in at least 20 prisoners, who escaped amid the chaos, and resulted in Batman, as part of a favor to Gordon, to round them up for the GCPD (as the police force was understaffed in large part due to the earlier riot).