• The energy would come from the trolley.

    Has the trolley come to a complete halt, or even showed down? If not, then either no energy has been transferred to the people and they just flop out, or we’ve just invented perpetual motion.