The Enterprise, docked at the orbiting Remmler Array, is evacuated in order to undergo a baryon sweep, a procedure that scans the ship with deadly rays in order to eliminate accumulated particles which have collected on the vessel over years of space travel. La Forge informs Picard that because baryon particle levels from the ship are so high, a more powerful sweep than normal may be needed to clear out all the radiation. Toward that end, La Forge ordered extra field diverters for the Bridge and the computer core, to further protect those sensitive areas from the sweep.
The senior officers, with the exception of Worf, who managed to get excused, attend a reception at the Arkaria Base on the planet below, hosted by Commander Hutchinson. However, Picard finds an excuse to leave the gathering, and with only minutes before the baryon sweep begins, he hurries to the Enterprise. But as he prepares to return to the planet, Picard notices that one of the technicians who came aboard is still there, working on a panel in a corridor. Suspicious of Picard's presence, the technician prepares to attack, but the captain gets the upper hand, striking the man and rendering him unconscious. Picard makes a run for the transporter room, but he is too late, the ship's primary power cuts off just as he steps onto the transporter pad.
Picard finds his unconscious assailant and drags him into Sickbay. When the man comes to, Picard commands him to reveal the real purpose of the technicians aboard the Enterprise. The man refuses comment, so Picard hyposprays him and takes his communicator, but is eventually captured by another member of the group, Kiros. Meanwhile, at the reception, the station administrator, Mr. Orton, leads a surprise takeover, firing alien phasers. Geordi is wounded, and Commander Hutchinson is killed. The officers are held hostage. The officers devise a plan to use the wounded Geordi's VISOR to emit a hypersonic pulse, which would render everyone but Data unconscious.
Picard gets away by escaping through a Jefferies tube — but his pursuer, Satler, is killed by the sweep. Picard contacts Kelsey, warning her against moving the volatile trilithium resin to Ten-Forward, where they are planning to go to avoid the sweep as long as possible. Kelsey, undaunted, has her assistant Neil put the substance in a container. Meanwhile, Picard arms himself with a crossbow, then goes to Sickbay, coats the arrow tips with a colored liquid, and finds two powders he can combine in order to create small explosions. He gets one of the thieves, Pomet, with an arrow in the leg, from which the liquid knocks out the alien. But Picard is once again caught by Kiros. Kelsey, now almost at Ten-Forward, murders Neil because she has no more use for him. Meeting Kiros, the two of them take Picard with them to Ten-Forward.
Back at the Arkaria Base, Riker orders their plan into motion, and soon everyone but Data slumps to the floor. Meanwhile, Picard reveals his true identity and offers himself as a hostage in lieu of the trilithium resin, but Kelsey turns down the deal since she intends to sell the substance rather than use it for terrorist purposes. Moving into Ten-Forward, Kiros steps into strips of Picard's two powders, which creates a small explosion that disables her. Picard and Kelsey fight for the trilithium resin. Suddenly, the sweep comes through the wall and Kelsey grabs the container, beaming over to a waiting ship, leaving Picard to face certain doom. Thinking quickly, he speaks into his communicator, urgently telling anyone who hears to deactivate the baryon sweep. With seconds to spare, the glow of the sweep fades. Data, having gained control on the Arkaria Base, has answered his captain's plea. Soon afterward, Kelsey's ship explodes, since Picard managed to steal the pin from the container of trilithium resin during their struggle.