@@ -0,0 +1,1240 @@
+package info.u_team.u_team_core.energy;%0A%0Aimport net.minecraft.nbt.CompoundNBT;%0Aimport net.minecraftforge.common.util.INBTSerializable;%0Aimport net.minecraftforge.energy.EnergyStorage;%0A%0Apublic class BasicEnergyStorage extends EnergyStorage implements INBTSerializable%3CCompoundNBT%3E %7B%0A%0A%09public BasicEnergyStorage(int capacity) %7B%0A%09%09this(capacity, capacity, capacity, 0);%0A%09%7D%0A%0A%09public BasicEnergyStorage(int capacity, int maxTransfer) %7B%0A%09%09this(capacity, maxTransfer, maxTransfer, 0);%0A%09%7D%0A%0A%09public BasicEnergyStorage(int capacity, int maxReceive, int maxExtract) %7B%0A%09%09this(capacity, maxReceive, maxExtract, 0);%0A%09%7D%0A%0A%09public BasicEnergyStorage(int capacity, int maxReceive, int maxExtract, int energy) %7B%0A%09%09super(capacity, maxReceive, maxExtract, energy);%0A%09%7D%0A%0A%09public void setEnergy(int energy) %7B%0A%09%09this.energy = energy;%0A%09%7D%0A%0A%09public void addEnergy(int energy) %7B%0A%09%09this.energy += energy;%0A%09%09if (this.energy %3E getMaxEnergyStored()) %7B%0A%09%09%09this.energy = getEnergyStored();%0A%09%09%7D%0A%09%7D%0A%0A%09@Override%0A%09public CompoundNBT serializeNBT() %7B%0A%09%09final CompoundNBT compound = new CompoundNBT();%0A%09%09compound.putInt(%22energy%22, getEnergyStored());%0A%09%09return compound;%0A%09%7D%0A%0A%09@Override%0A%09public void deserializeNBT(CompoundNBT compound) %7B%0A%09%09setEnergy(compound.getInt(%22energy%22));%0A%09%7D%0A%0A%7D%0A

Add basic energy storage