Package net.minecraft.tileentity
Class BeaconTileEntity
- java.lang.Object
-
- net.minecraftforge.common.capabilities.CapabilityProvider<TileEntity>
-
- net.minecraft.tileentity.TileEntity
-
- net.minecraft.tileentity.BeaconTileEntity
-
- All Implemented Interfaces:
IContainerProvider
,INamedContainerProvider
,ITickableTileEntity
,ICapabilityProvider
,ICapabilitySerializable<CompoundNBT>
,IForgeTileEntity
,INBTSerializable<CompoundNBT>
public class BeaconTileEntity extends TileEntity implements INamedContainerProvider, ITickableTileEntity
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BeaconTileEntity.BeamSegment
-
Field Summary
Fields Modifier and Type Field Description static Effect[][]
BEACON_EFFECTS
private java.util.List<BeaconTileEntity.BeamSegment>
beamSections
private java.util.List<BeaconTileEntity.BeamSegment>
checkingBeamSections
private IIntArray
dataAccess
private int
lastCheckY
private int
levels
private LockCode
lockKey
private ITextComponent
name
private Effect
primaryPower
private Effect
secondaryPower
private static java.util.Set<Effect>
VALID_EFFECTS
-
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 BeaconTileEntity()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
applyEffects()
Container
createMenu(int p_createMenu_1_, PlayerInventory p_createMenu_2_, PlayerEntity p_createMenu_3_)
java.util.List<BeaconTileEntity.BeamSegment>
getBeamSections()
ITextComponent
getDisplayName()
int
getLevels()
SUpdateTileEntityPacket
getUpdatePacket()
CompoundNBT
getUpdateTag()
private static Effect
getValidEffectById(int p_184279_0_)
double
getViewDistance()
void
load(BlockState p_230337_1_, CompoundNBT p_230337_2_)
void
playSound(SoundEvent p_205736_1_)
CompoundNBT
save(CompoundNBT p_189515_1_)
void
setCustomName(ITextComponent p_200227_1_)
void
setRemoved()
void
tick()
private void
updateBase(int p_213927_1_, int p_213927_2_, int p_213927_3_)
-
Methods inherited from class net.minecraft.tileentity.TileEntity
clearCache, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getTileData, getType, hasLevel, isRemoved, loadStatic, logInvalidState, mirror, onChunkUnloaded, onlyOpCanSetNbt, rotate, setChanged, setLevelAndPosition, setPosition, 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
-
BEACON_EFFECTS
public static final Effect[][] BEACON_EFFECTS
-
VALID_EFFECTS
private static final java.util.Set<Effect> VALID_EFFECTS
-
beamSections
private java.util.List<BeaconTileEntity.BeamSegment> beamSections
-
checkingBeamSections
private java.util.List<BeaconTileEntity.BeamSegment> checkingBeamSections
-
levels
private int levels
-
lastCheckY
private int lastCheckY
-
primaryPower
@Nullable private Effect primaryPower
-
secondaryPower
@Nullable private Effect secondaryPower
-
name
@Nullable private ITextComponent name
-
lockKey
private LockCode lockKey
-
dataAccess
private final IIntArray dataAccess
-
-
Method Detail
-
tick
public void tick()
- Specified by:
tick
in interfaceITickableTileEntity
-
updateBase
private void updateBase(int p_213927_1_, int p_213927_2_, int p_213927_3_)
-
setRemoved
public void setRemoved()
- Overrides:
setRemoved
in classTileEntity
-
applyEffects
private void applyEffects()
-
playSound
public void playSound(SoundEvent p_205736_1_)
-
getBeamSections
public java.util.List<BeaconTileEntity.BeamSegment> getBeamSections()
-
getLevels
public int getLevels()
-
getUpdatePacket
@Nullable public SUpdateTileEntityPacket getUpdatePacket()
- Overrides:
getUpdatePacket
in classTileEntity
-
getUpdateTag
public CompoundNBT getUpdateTag()
- Overrides:
getUpdateTag
in classTileEntity
-
getViewDistance
public double getViewDistance()
- Overrides:
getViewDistance
in classTileEntity
-
getValidEffectById
@Nullable private static Effect getValidEffectById(int p_184279_0_)
-
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
-
setCustomName
public void setCustomName(@Nullable ITextComponent p_200227_1_)
-
createMenu
@Nullable public Container createMenu(int p_createMenu_1_, PlayerInventory p_createMenu_2_, PlayerEntity p_createMenu_3_)
- Specified by:
createMenu
in interfaceIContainerProvider
-
getDisplayName
public ITextComponent getDisplayName()
- Specified by:
getDisplayName
in interfaceINamedContainerProvider
-
-