Package net.minecraft.tileentity
Class BeehiveTileEntity
- java.lang.Object
-
- net.minecraftforge.common.capabilities.CapabilityProvider<TileEntity>
-
- net.minecraft.tileentity.TileEntity
-
- net.minecraft.tileentity.BeehiveTileEntity
-
- All Implemented Interfaces:
ITickableTileEntity
,ICapabilityProvider
,ICapabilitySerializable<CompoundNBT>
,IForgeTileEntity
,INBTSerializable<CompoundNBT>
public class BeehiveTileEntity extends TileEntity implements ITickableTileEntity
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
BeehiveTileEntity.Bee
static class
BeehiveTileEntity.State
-
Field Summary
Fields Modifier and Type Field Description private BlockPos
savedFlowerPos
private java.util.List<BeehiveTileEntity.Bee>
stored
-
Fields inherited from class net.minecraft.tileentity.TileEntity
level, remove, worldPosition
-
Fields inherited from interface net.minecraftforge.common.extensions.IForgeTileEntity
INFINITE_EXTENT_AABB
-
-
Constructor Summary
Constructors Constructor Description BeehiveTileEntity()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addOccupant(Entity p_226961_1_, boolean p_226961_2_)
void
addOccupantWithPresetTicks(Entity p_226962_1_, boolean p_226962_2_, int p_226962_3_)
void
emptyAllLivingFromHive(PlayerEntity p_226963_1_, BlockState p_226963_2_, BeehiveTileEntity.State p_226963_3_)
static int
getHoneyLevel(BlockState p_226964_0_)
int
getOccupantCount()
private boolean
hasSavedFlowerPos()
boolean
isEmpty()
boolean
isFireNearby()
boolean
isFull()
boolean
isSedated()
void
load(BlockState p_230337_1_, CompoundNBT p_230337_2_)
private java.util.List<Entity>
releaseAllOccupants(BlockState p_226965_1_, BeehiveTileEntity.State p_226965_2_)
private boolean
releaseOccupant(BlockState p_235651_1_, BeehiveTileEntity.Bee p_235651_2_, java.util.List<Entity> p_235651_3_, BeehiveTileEntity.State p_235651_4_)
CompoundNBT
save(CompoundNBT p_189515_1_)
protected void
sendDebugPackets()
private void
setBeeReleaseData(int p_235650_1_, BeeEntity p_235650_2_)
void
setChanged()
void
tick()
private void
tickOccupants()
ListNBT
writeBees()
-
Methods inherited from class net.minecraft.tileentity.TileEntity
clearCache, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getTileData, getType, getUpdatePacket, getUpdateTag, getViewDistance, hasLevel, isRemoved, loadStatic, logInvalidState, mirror, onChunkUnloaded, onlyOpCanSetNbt, rotate, setLevelAndPosition, setPosition, setRemoved, triggerEvent
-
Methods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCaps
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.minecraftforge.common.capabilities.ICapabilityProvider
getCapability, getCapability
-
Methods inherited from interface net.minecraftforge.common.extensions.IForgeTileEntity
deserializeNBT, deserializeNBT, getModelData, getRenderBoundingBox, getTileEntity, handleUpdateTag, onDataPacket, onLoad, requestModelDataUpdate, serializeNBT
-
-
-
-
Field Detail
-
stored
private final java.util.List<BeehiveTileEntity.Bee> stored
-
savedFlowerPos
@Nullable private BlockPos savedFlowerPos
-
-
Method Detail
-
setChanged
public void setChanged()
- Overrides:
setChanged
in classTileEntity
-
isFireNearby
public boolean isFireNearby()
-
isEmpty
public boolean isEmpty()
-
isFull
public boolean isFull()
-
emptyAllLivingFromHive
public void emptyAllLivingFromHive(@Nullable PlayerEntity p_226963_1_, BlockState p_226963_2_, BeehiveTileEntity.State p_226963_3_)
-
releaseAllOccupants
private java.util.List<Entity> releaseAllOccupants(BlockState p_226965_1_, BeehiveTileEntity.State p_226965_2_)
-
addOccupant
public void addOccupant(Entity p_226961_1_, boolean p_226961_2_)
-
getOccupantCount
public int getOccupantCount()
-
getHoneyLevel
public static int getHoneyLevel(BlockState p_226964_0_)
-
isSedated
public boolean isSedated()
-
sendDebugPackets
protected void sendDebugPackets()
-
addOccupantWithPresetTicks
public void addOccupantWithPresetTicks(Entity p_226962_1_, boolean p_226962_2_, int p_226962_3_)
-
releaseOccupant
private boolean releaseOccupant(BlockState p_235651_1_, BeehiveTileEntity.Bee p_235651_2_, @Nullable java.util.List<Entity> p_235651_3_, BeehiveTileEntity.State p_235651_4_)
-
setBeeReleaseData
private void setBeeReleaseData(int p_235650_1_, BeeEntity p_235650_2_)
-
hasSavedFlowerPos
private boolean hasSavedFlowerPos()
-
tickOccupants
private void tickOccupants()
-
tick
public void tick()
- Specified by:
tick
in interfaceITickableTileEntity
-
load
public void load(BlockState p_230337_1_, CompoundNBT p_230337_2_)
- Overrides:
load
in classTileEntity
-
save
public CompoundNBT save(CompoundNBT p_189515_1_)
- Overrides:
save
in classTileEntity
-
writeBees
public ListNBT writeBees()
-
-