they got a piston inside a cylinder, when you cock it, the piston is pushed all the way back and stays there, til you close the barel and pull the trigger... which lets the piston compress thus shooting the pellet out the barrel. quite a simple mechanism.