Function move_energy
pub fn move_energy(
host: &mut dyn ServerHost,
from: &Capability<dyn EnergyHandler>,
to: &Capability<dyn EnergyHandler>,
max: u32,
tx: &Transaction,
) -> Result<u32, Overanswered>Expand description
Moves up to max energy out of from into to (NeoForge’s EnergyHandlerUtil.move), in
transaction tx: how much moved. As one step of move_resources: all or nothing in a
transaction of its own, a move to takes only part of tried again with that part, and a
handler answering more than it was asked ending it with Overanswered.