GUYS! I FIGURED IT OUT!
Most engines, 1225 included, had sanders to lay down sand for each side of the wheels, you could sand each side INDIVIDUALLY.
At first, the dude uses the inertia to turn around, but turns using inertia and sanding, therefore "drifting" the train.
Also, clearly, at the end, when they're going up the grade, he's out of sand, as evidenced by the extreme wheelslip