This commit is contained in:
Shadows_of_Fire 2017-10-05 09:06:26 -04:00
parent 6a16bbfc4b
commit 19402f3650
2 changed files with 2 additions and 2 deletions

View file

@ -55,7 +55,7 @@ public class ItemBattery extends ItemEnergy{
EntityPlayer player = (EntityPlayer)entity;
for(int i = 0; i < player.inventory.getSizeInventory(); i++){
ItemStack slot = player.inventory.getStackInSlot(i);
if(StackUtil.isValid(slot)){
if(StackUtil.isValid(slot) && slot.getCount() == 1){
int extractable = this.extractEnergy(stack, Integer.MAX_VALUE, true);
int received = 0;

View file

@ -78,7 +78,7 @@ public class TileEntityPlayerInterface extends TileEntityBase implements IEnergy
for(int i = 0; i < player.inventory.getSizeInventory(); i++){
if(this.storage.getEnergyStored() > 0){
ItemStack slot = player.inventory.getStackInSlot(i);
if(StackUtil.isValid(slot)){
if(StackUtil.isValid(slot) && slot.getCount() == 1){
int received = 0;
if(slot.hasCapability(CapabilityEnergy.ENERGY, null)){