The Time Gauntlet is a time manipulating weapon used by the self repairing Simulant known as The Inquisitor. He survived to the end of time itself and concluded that there is no god or afterlife of any kind and that the purpose of existence is to live a worthwhile life, so after constructing the Time Gauntlet he travels through time and space, judging each sentient lifeform, erasing those who wasted their lives and replacing them with those who never had a chance of life (the unfertilized ova, the sperm that never made it).
After he judges the boys from the Dwarf (more specifically, Lister and Kryten) the Inquisitor tries to erase them but a future version of Kryten slices off the Inquisitor's hand with a holo-saw and throws the others the gauntlet, after telling them of details of the "final confrontation", Kryten is then killed by having his head crushed. After running from the Inquisitor Kryten goes back to sacrifice himself, so that they get into the mess they're in, in the first place.
Lister dangles the Inquisitor over a chasm, threatening to kill him, then he saves him, reasoning that if Lister is erased, he won't be there to save him and he'll die, but the Inquisitor reasons that he can erase him from the timeline quite safely as he wouldn't exist to threaten his life in the first place. It turns out that Kryten, under Lister's instructions, reprogrammed the gauntlet to backfire and erase the wearer, if the "erase" function is used, which erases the wearer. This undoes everything the Inquisitor ever did, and restores Kryten, Rimmer and the Cat to life. ("The Inquisitor")