diff options
Diffstat (limited to 'src/main/java/gregtech/common/tileentities')
| -rw-r--r-- | src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java index f442b6812c..7562946e51 100644 --- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java +++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java @@ -207,8 +207,16 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM { ItemStack s = dropstacks.get(entry.getKey()).copy(); s.stackSize = entry.getValue().intValue() + (getWorld().rand.nextFloat() < (entry.getValue() - (float) entry.getValue().intValue()) ? 1 : 0); - if(s.stackSize > 0) - this.mOutputItems[i++] = s; + if(s.stackSize > 0 && i < 7) + while(true) { + if (s.stackSize <= s.getMaxStackSize()) { + this.mOutputItems[i++] = s; + break; + } else + this.mOutputItems[i++] = s.splitStack(s.getMaxStackSize()); + if(i >= 7) + break; + } } IApiaristTracker breedingTracker = beeRoot.getBreedingTracker(getWorld(), getOwner()); |
