Let us look at mechanics as-if caloric...
We take 2 flywheels.
we spin them up to speed.
both wheels are spinning at the same speed.
We extract some energy from flywheel 1. (say 10 Joule)
We now have a fast(2) and a slow(1) spinning flywheel.
If we hook up the axle of flywheel 1 to flywheel 2 with a rotating generator, we gain an equal amount of energy as that what we took out.
There is a potential difference!
When we use-up this energy flywheel 1 and flywheel 2 both spin slower but at the same speed again. Thus establishing equilibrium is a 100% gain cycle.
By redividing the energy loss over the 2 flywheels we gain energy!
The load we apply always ends up slowing wheel 2 down and speeding wheel 1 up until they are back in balance.
Isn't that fantastic?