For Ray's birthday, the 125 shuts down and holds a rowdy party: heavy drinking, dancing with hookers, etc. The next morning, Sam wakes up hung-over at the precinct to answer a phone call... from his mother in 2008. She tells him unless he gives her a sign, she will turn off his life support at 2 pm. Sam screams for her not to, but she can't hear him. Lieutenant Hunt walks into the squad room, waking up his bleary-eyed detectives and informing them there's a hostage situation at Memorial Hospital.
It's pure chaos at the hospital when the team arrives and Hunt takes charge. A man armed with a shotgun grabbed a psychosurgeon named Dr. Schwahn and is holding an undetermined number of hostages. He demands a surgical nurse and an EEG machine. If his demands are not met by 2 pm, he will kill the hostages. Sam makes a connection between his mother's call and the situation. He believes he can send a sign to his mother by preventing anyone from dying during the standoff. Unfortunately, Hunt's idea of hostage resolution tactics involves a body count.
Sam tries calling the perp. He's unable to keep the man on the line but is freaked out that somehow the guy knows his name. Sam dials the phone again, to no avail. All Annie or Chris discover is that Dr. Schwahn performs lobotomies and the hostage-taker signed into the hospital under the name Michael H.
Before Sam can act on the information he sees Ray and the men of the 125 loading their weapons, preparing to move in. Through a bullhorn, Hunt gives Michael one last warning. As Ray signals his armed men towards the hospital, Michael starts shooting into the street. The police return fire. Desperate to prevent any killing, Sam hands his badge and gun to Annie and runs into the middle of the gunfight with his hands up. Everyone holds fire as Sam calmly persuades Michael to let him into the hospital.
In the psychiatric ward, Michael reveals that Dr. Schwahn, currently gagged and locked in a cage, once treated his brother Johnny for schizophrenia using a procedure that literally fried his brain. Michael wants the EEG machine so Dr. Schwahn can undo the damage. Just then, Hunt calls Michael to say they're sending in the machine. Hunt then asks for Sam. As soon as Sam picks up the phone, Hunt begins chewing him out. Sam cuts him off and speaks in code; he gives Hunt the number of hostages by saying how many are okay; he relays which side of the building they're on by mentioning the sun is shining on him; he hints they're in the psych ward by saying Michael H. is "no psycho." After initial confusion, an impressed Hunt catches on.
Upstairs, Sam asks Michael about his endgame. Michael reveals he's wearing a vest bomb. He exits, locking his hostages in the room. One of the patients, Erica, approaches Sam and introduces herself as a newspaper reporter, working undercover to research mistreatment of psych patients. When Sam asks where Michael keeps disappearing to, she answers "South of the Slot," but her description of the place sounds like gibberish. Sam can't tell if she's really a reporter or just a psycho claiming to be one.
While looking for a way to escape the locked down psych ward, Sam notices a soap opera on television... the actress on screen is Maya! He approaches the TV to watch the "show" (or his delusion of one) in which a doctor and mother tell Maya to let her comatose boyfriend go. Maya notices her boyfriend's hand twitch. Surprised, she asks if it's really him. Sam desperately yells at the TV that he's there, but she can't hear him.
Just then, Sam notices Dr. Schwahn has pulled off his gag. Knowing Schwahn can't fix Johnny, Sam admonishes the doctor and his practices. Schwahn defends his work. He tells Sam that Erica is not a reporter but a patient whose delusions led her to kill her family. Schwahn believes his work is necessary because his patients' fantasies -- time travel, parallel dimensions, thinking radios or televisions are communicating with them -- usually end in tragedy. This obviously affects Sam.
Michael returns to untie Schwahn so he can operate. As he does, an orderly grabs a scalpel and lunges at Michael, who shoots him in self-defense. Desperate to keep the orderly alive, Sam ignores Michael's order to back off and performs CPR. Michael knocks Sam out with the butt of his shotgun.
Sam wakes up to find Annie, dressed as a nurse, and Lt. Hunt, dressed as an EMT inside the psych ward, checking on him. After making sure Sam is okay, Hunt tells Sam his plan... He has three .38s hidden in the EEG machine. When his men storm in, they will kill Michael before he can detonate his vest bomb. However, Hunt's plan is thrown when Michael locks the machine inside the cage. Now, Sam must warn Ray and the others about the bomb before they do anything rash.
Annie gives Sam the janitor's key she has hidden in her bra that will let him out of the ward. Sam makes a plan to climb out an unbarred window he saw earlier, but when he and Hunt arrive there, the window isn't there. Sam doesn't understand. The window must have been a hallucination. Instead, the men find a closet packed with explosives. They hear a scream from the psych ward and rush back.
Having found the pistols in the machine, a livid Michael has strapped the vest bomb onto Annie. He forces Sam to call Ray with a list of demands. Ray refuses to listen, but Sam rips down the curtains so Ray can see Annie wrapped in explosives. Ray listens to the demands; a bus, a plane, and a pilot.
A short time later, Annie and Sam are handcuffed to a bed. Annie is no longer wearing the bomb vest. She tells Sam about a schizophrenic she knew who was able to live normally by clinging to a happy memory he was sure was real. Sam describes the first time he met Maya as his happy memory, one that made life worth living.
Later, Hunt, Sam and Annie find themselves chained to a radiator in an operating room. Dr. Schwahn tells them his plan to manipulate the EEG machine so it looks like he's fixed Johnny. Michael enters, back in his bomb vest, and instructs Schwahn to proceed with the surgery. Before the doctor drills into Johnny's head, Sam screams at the doctor not to do it. Sam tells Michael the surgery won't work, which prompts Michael to start wailing on him. Hunt and Annie beg him to stop, but he keeps punching Sam until Dr. Schwahn breaks down and admits that Sam's right.
At the barrel of Michael's shotgun, Annie tapes the hands and mouths of all the hostages, clothes them in identical doctor's coats, and places pillowcases with eye holes over their heads. Unlike the other hostages, Sam is dressed in Michael's jacket and has a shotgun taped to his hands. Michael tapes Sam's mouth shut and pulls a ski mask over his head, then dresses Annie and himself like the other hostages. Before herding everyone out, he yells, "See you all South of the Slot."
Once the hostages exit the building and make their way towards the bus, police snipers open fire on Sam, believing he's Michael. Hunt and Annie pile on top of Sam to protect him. Ray tells his men to hold their fire and takes the masks off Hunt, Annie and Sam. The team takes the pillowcases off the rest of the hostages and realizes that Michael and Johnny are missing. Lt. Hunt orders everyone to evacuate, but Sam runs back in.
Sam races down a corridor underneath the hospital and finds Michael and Johnny. Michael explains his plan was to demolish the hospital in order to create a distraction while he and Johnny fled to Canada. But now that Sam has ruined his plan, he's willing to blow himself, his brother and everyone else up. A clock ticks closer to 2:00. As Sam steps between Michael and the bomb switch panel, he hears voices from his 2008 hospital room, about to turn off his life support. Michael aims his pistol at Sam and pulls the hammer. Sam closes his eyes and finds himself in 2007, reliving the moment when he first met Maya. The details of the bar, the music and Maya make him smile. He hears a surprised female voice say, "He's smiling!"
Back in the corridor, Sam opens his eyes. The clock ticks past 2:00. Sam notices Michael is distracted. He's staring at Johnny, who's smiling. The detectives rush to the scene and take Michael down, but not before he gets a shot off and hits Hunt in the chest. Sam is relieved when Hunt gets up and shows his men that the bullet hit one of the three flasks in his pockets.
Outside the hospital, the men celebrate their victory. On his way home, through a window, Sam glances at a TV showing the same soap opera from the hospital. He watches the mother refusing to let the doctors near her son because she saw him smile. Annie catches Sam peeping, but Sam takes the moment to thank her for helping him remember a happy moment. Annie walks into a bar. Before he walks off, Sam again sees Maya on the television. In tears, she tells her lover she can't do this anymore, that she has to leave him. Sam is blown away, but feels a little better when he sees Annie through the window of the bar. They lock eyes as we see the name of the soap opera: "Life On Mars".