diff --git a/src/main/java/forestry/apiculture/gadgets/TileSwarm.java b/src/main/java/forestry/apiculture/gadgets/TileSwarm.java index e0bb93925..2f59e7156 100755 --- a/src/main/java/forestry/apiculture/gadgets/TileSwarm.java +++ b/src/main/java/forestry/apiculture/gadgets/TileSwarm.java @@ -15,6 +15,7 @@ import forestry.core.inventory.InventoryAdapter; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntity; +import net.minecraft.world.EnumSkyBlock; public class TileSwarm extends TileEntity { @@ -22,7 +23,21 @@ public class TileSwarm extends TileEntity { @Override public boolean canUpdate() { - return false; + return true; + } + + // Hack to make sure that hives glow. + // TODO: remove when Mojang fixes this bug: https://bugs.mojang.com/browse/MC-3329 + // Hives should not need to tick normally. + private boolean updatedLight; + + @Override + public void updateEntity() { + super.updateEntity(); + + if (worldObj.isRemote && !updatedLight && worldObj.getWorldTime() % 20 == 0) { + updatedLight = worldObj.updateLightByType(EnumSkyBlock.Block, xCoord, yCoord, zCoord); + } } public TileSwarm setContained(ItemStack[] bees) {