Carter has Dr. Keller and Rodney go with her to M5V-801 to help the natives with their respiratory problems by convincing them to move. The Genii forced the locals to mine some unknown substance 20 years ago and then left, and the aliens insist on payment to move. Sam has to go and manage the negotiations. Arriving on the planet, Rodney falls through a hole in the surface… and Keller and Carter fall through seconds later.
Recovering, they determine they've fallen into an abandoned Genii mining facility. The doors are sealed but they manage to get one open, only to find a chamber with a gaping chasm in the floor, elevated on metal stilts. With five hours left until they have to check in, McKay tries to decipher the security lock on another door. A tremor shakes the facility and they realize with their extra weight the room is at risk. They have to find a way out before their room falls into the chasm. There are barely enough crates to stack to reach the hole in the ceiling so they go to work, but the lower crates break, spilling Sam to the floor.
Searching the room, McKay finds some grappling hooks and ropes and the women start knotting the rope while Rodney goes over some Genii files for useful information. They hear voices up above and yell for help, and see two young boys. However, they refuse to say anything to their parents because they'll get in trouble for playing near the mining facility. They run off and the people work on the rope while discussing Rodney's relationship problems. They finally get the rope ready and hear more voices above. The two boys are back with their friends. However, they refuse to bring their parents and run off when Rodney threatens them. Another tremor shakes the place starts to tilt over but stops.
McKay tries to throw the hook up but isn't very good at it. He manages to break open a gas pipe and ignite a fire, and Sam turns off the valve. Sam takes over and manages to snag the hook up above, but there's nothing solid for it to attach to. Rodney suggests they climb up to some higher beams and build a bridge, and Keller remembers a bar bet about using three knifes to spam three cups and support a fourth. They use beams in the room to do the same thing, with Rodney promising Keller he'll buy her a beer if it works. They then stack the crates up and Sam manages to get right up to the hole… but another tremor causes the beams to break and Sam falls and breaks her leg.
Keller makes a splint but warns there may be internal bleeding and Carter has maybe an hour. McKay improvises a cannon with a tube and a detonator and fires a metal rod up using the gas from the leaking pipe. They fire the rod with the rope up and it anchors, but the room tilts and Keller plummets out the door and into the chasm. Only her hold on the rope helps her, but Rodney is left holding onto the rope. Carter can't help him and McKay starts to pull her up, but she says she sees daylight through a mineshaft. She has McKay lower her down since the hole above is sealed over. Keller gets into the mineshaft and McKay offers to lower Carter down, but his hands are badly abraded. He rigs up a seat and lowers her down despite the agony. McKay manages to get down but can't bring himself to swing over. Keller finally convinces him to swing over just as the facility falls into the chasm.
Back at Atlantis, McKay and Carter get their injuries tended to and Keller thanks McKay for saving her. Before he can, she reminds him that he owes her a beer and insists that she join him for a drink, much to his astonishment… and pleasure.