mirror of
https://github.com/GTNewHorizons/EnderIO.git
synced 2026-11-21 12:42:36 +00:00
#1144 Wireless charger not keeping its charge when the game / chunk is unloaded
This commit is contained in:
1 parent
f386bcc504
commit
6506d72857
2 files changed
+4
-3
No files matched your search
@@ -83,7 +83,7 @@ public class TileWirelessCharger extends TileEntityEio implements IInternalPower
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void writeCustomNBT(NBTTagCompound root) {
|
||||
protected void writeCustomNBT(NBTTagCompound root) {
|
||||
root.setInteger("storedEnergyRF", storedEnergyRF);
|
||||
}
|
||||
|
||||
@@ -93,7 +93,7 @@ public class TileWirelessCharger extends TileEntityEio implements IInternalPower
|
||||
double storedMJ = root.getDouble("storedEnergy");
|
||||
storedEnergyRF = (int)(storedMJ * 10);
|
||||
} else {
|
||||
storedEnergyRF = root.getInteger("storedEnergy");
|
||||
storedEnergyRF = root.getInteger("storedEnergyRF");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ public class TileWirelessCharger extends TileEntityEio implements IInternalPower
|
||||
}
|
||||
|
||||
@Override
|
||||
public int receiveEnergy(ForgeDirection from, int maxReceive, boolean simulate) {
|
||||
public int receiveEnergy(ForgeDirection from, int maxReceive, boolean simulate) {
|
||||
return PowerHandlerUtil.recieveInternal(this, maxReceive, from, simulate);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user