Class SculkSensorBlockEntity
java.lang.Object
net.minecraftforge.common.capabilities.CapabilityProvider<BlockEntity>
net.minecraft.world.level.block.entity.BlockEntity
net.minecraft.world.level.block.entity.SculkSensorBlockEntity
- All Implemented Interfaces:
VibrationListener.VibrationListenerConfig,ICapabilityProvider,ICapabilityProviderImpl<BlockEntity>,ICapabilitySerializable<CompoundTag>,IForgeBlockEntity,INBTSerializable<CompoundTag>
public class SculkSensorBlockEntity
extends BlockEntity
implements VibrationListener.VibrationListenerConfig
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
CapabilityProvider.AsField<B extends ICapabilityProviderImpl<B>> -
Field Summary
FieldsFields inherited from class net.minecraft.world.level.block.entity.BlockEntity
level, remove, worldPositionFields inherited from interface net.minecraftforge.common.extensions.IForgeBlockEntity
INFINITE_EXTENT_AABB -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintstatic intgetRedstoneStrengthForDistance(int p_155651_, int p_155652_) voidload(CompoundTag p_155649_) voidonSignalReceive(Level p_155638_, GameEventListener p_155639_, GameEvent p_155640_, int p_155641_) protected voidsaveAdditional(CompoundTag p_187511_) booleanshouldListen(Level p_155643_, GameEventListener p_155644_, BlockPos p_155645_, GameEvent p_155646_, Entity p_155647_) Methods inherited from class net.minecraft.world.level.block.entity.BlockEntity
addEntityType, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPosFromTag, getTileData, getType, getUpdatePacket, getUpdateTag, hasLevel, isRemoved, loadStatic, onChunkUnloaded, onlyOpCanSetNbt, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setBlockState, setChanged, setChanged, setLevel, setRemoved, triggerEventMethods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCapsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraftforge.common.capabilities.ICapabilityProvider
getCapability, getCapabilityMethods inherited from interface net.minecraftforge.common.extensions.IForgeBlockEntity
deserializeNBT, getModelData, getRenderBoundingBox, handleUpdateTag, onDataPacket, onLoad, requestModelDataUpdate, serializeNBT
-
Field Details
-
listener
-
lastVibrationFrequency
private int lastVibrationFrequency
-
-
Constructor Details
-
SculkSensorBlockEntity
-
-
Method Details
-
load
- Overrides:
loadin classBlockEntity
-
saveAdditional
- Overrides:
saveAdditionalin classBlockEntity
-
getListener
-
getLastVibrationFrequency
public int getLastVibrationFrequency() -
shouldListen
public boolean shouldListen(Level p_155643_, GameEventListener p_155644_, BlockPos p_155645_, GameEvent p_155646_, @Nullable Entity p_155647_) - Specified by:
shouldListenin interfaceVibrationListener.VibrationListenerConfig
-
onSignalReceive
public void onSignalReceive(Level p_155638_, GameEventListener p_155639_, GameEvent p_155640_, int p_155641_) - Specified by:
onSignalReceivein interfaceVibrationListener.VibrationListenerConfig
-
getRedstoneStrengthForDistance
public static int getRedstoneStrengthForDistance(int p_155651_, int p_155652_)
-