********* The difference between and impact gun an a powered ratchet is that an impact gun has hammers and an anvil. The hammers strike or impact the anvil, which turns the shaft, and the blows from the hammers striking the anvil generate more torque than a motor or turbine spinning the shaft. The difference is basically the same as the difference between a hammer drill and a rotary drill.
Pneumatic impact guns used in automotive applications generally come in one of 2 configurations. One looks like a drill and is the one used most often on wheel lug nuts because the handle allows for a more comfortable grip, and the other looks like a rectangular box with a paddle on one surface. Pushing the paddle one way or the other allows easier changing of direction, and the box without the pistol grip allows reaching in tighter spaces. The torque generated by an impact gun depends on air volume, air pressure, and the size of the hammers and anvil.
A powered ratchet does not generate as much torque as an impact gun, and when the fastener is tightened, the ratchet has a tendency to spin in the opposite direction, something the impact gun doesn't do.
I bet you saw a technician using an air ratchet to run the lug nuts down to the wheel since the air ratchet doesn't generate enough torque to over-tighten the lug nuts, and then tightening the lug nuts with a torque wrench.