Package net.minecraft.block.entity
Class SculkSensorBlockEntity
java.lang.Object
net.minecraft.block.entity.BlockEntity
net.minecraft.block.entity.SculkSensorBlockEntity
- All Implemented Interfaces:
VibrationListener.Callback
- Mappings:
Namespace Name official cuhintermediary net/minecraft/class_5704named net/minecraft/block/entity/SculkSensorBlockEntity
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final org.slf4j.Loggerprivate intprivate VibrationListenerFields inherited from class net.minecraft.block.entity.BlockEntity
pos, removed, world -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(ServerWorld world, GameEventListener listener, BlockPos pos, GameEvent event, @Nullable Entity entity, @Nullable Entity sourceEntity, float distance) Accepts a game event after delay.booleanaccepts(ServerWorld world, GameEventListener listener, BlockPos pos, GameEvent event, GameEvent.Emitter emitter) Returns whether the callback wants to accept this event.intstatic intgetPower(float distance, int range) voidonListen()voidreadNbt(NbtCompound nbt) Reads data fromnbt.voidsetLastVibrationFrequency(int lastVibrationFrequency) booleanprotected voidwriteNbt(NbtCompound nbt) Writes data tonbt.Methods inherited from class net.minecraft.block.entity.BlockEntity
cancelRemoval, copyItemDataRequiresOperator, createFromNbt, createNbt, createNbtWithId, createNbtWithIdentifyingData, getCachedState, getPos, getType, getWorld, hasWorld, isRemoved, markDirty, markDirty, markRemoved, onSyncedBlockEvent, populateCrashReport, posFromNbt, setCachedState, setStackNbt, setWorld, toInitialChunkDataNbt, toUpdatePacket, writeIdToNbtMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.world.event.listener.VibrationListener.Callback
canAccept, getTag
-
Field Details
-
field_38236
private static final org.slf4j.Logger field_38236- Mappings:
Namespace Name Mixin selector official aLcuh;a:Lorg/slf4j/Logger;intermediary field_38236Lnet/minecraft/class_5704;field_38236:Lorg/slf4j/Logger;named field_38236Lnet/minecraft/block/entity/SculkSensorBlockEntity;field_38236:Lorg/slf4j/Logger;
-
listener
- Mappings:
Namespace Name Mixin selector official bLcuh;b:Ldab;intermediary field_28118Lnet/minecraft/class_5704;field_28118:Lnet/minecraft/class_5718;named listenerLnet/minecraft/block/entity/SculkSensorBlockEntity;listener:Lnet/minecraft/world/event/listener/VibrationListener;
-
lastVibrationFrequency
private int lastVibrationFrequency- Mappings:
Namespace Name Mixin selector official cLcuh;c:Iintermediary field_28119Lnet/minecraft/class_5704;field_28119:Inamed lastVibrationFrequencyLnet/minecraft/block/entity/SculkSensorBlockEntity;lastVibrationFrequency:I
-
-
Constructor Details
-
SculkSensorBlockEntity
- Mappings:
Namespace Name Mixin selector official <init>Lcuh;<init>(Lgt;Lcvo;)Vintermediary <init>Lnet/minecraft/class_5704;<init>(Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)Vnamed <init>Lnet/minecraft/block/entity/SculkSensorBlockEntity;<init>(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
-
-
Method Details
-
readNbt
Reads data fromnbt. Subclasses should override this if they store a persistent data.NBT is a storage format; therefore, a data from NBT is loaded to a block entity instance's fields, which are used for other operations instead of the NBT. The data is written back to NBT when saving the block entity.
nbtmight not have all expected keys, or might have a key whose value does not meet the requirement (such as the type or the range). This method should fall back to a reasonable default value instead of throwing an exception.- Overrides:
readNbtin classBlockEntity- See Also:
- Mappings:
Namespace Name Mixin selector official aLcti;a(Lpj;)Vintermediary method_11014Lnet/minecraft/class_2586;method_11014(Lnet/minecraft/class_2487;)Vnamed readNbtLnet/minecraft/block/entity/BlockEntity;readNbt(Lnet/minecraft/nbt/NbtCompound;)V
-
writeNbt
Writes data tonbt. Subclasses should override this if they store a persistent data.NBT is a storage format; therefore, a data from NBT is loaded to a block entity instance's fields, which are used for other operations instead of the NBT. The data is written back to NBT when saving the block entity.
- Overrides:
writeNbtin classBlockEntity- See Also:
- Mappings:
Namespace Name Mixin selector official bLcti;b(Lpj;)Vintermediary method_11007Lnet/minecraft/class_2586;method_11007(Lnet/minecraft/class_2487;)Vnamed writeNbtLnet/minecraft/block/entity/BlockEntity;writeNbt(Lnet/minecraft/nbt/NbtCompound;)V
-
getEventListener
- Mappings:
Namespace Name Mixin selector official cLcuh;c()Ldab;intermediary method_32911Lnet/minecraft/class_5704;method_32911()Lnet/minecraft/class_5718;named getEventListenerLnet/minecraft/block/entity/SculkSensorBlockEntity;getEventListener()Lnet/minecraft/world/event/listener/VibrationListener;
-
getLastVibrationFrequency
public int getLastVibrationFrequency()- Mappings:
Namespace Name Mixin selector official dLcuh;d()Iintermediary method_32912Lnet/minecraft/class_5704;method_32912()Inamed getLastVibrationFrequencyLnet/minecraft/block/entity/SculkSensorBlockEntity;getLastVibrationFrequency()I
-
triggersAvoidCriterion
public boolean triggersAvoidCriterion()- Specified by:
triggersAvoidCriterionin interfaceVibrationListener.Callback- Mappings:
Namespace Name Mixin selector official tLdab$b;t()Zintermediary method_43695Lnet/minecraft/class_5718$class_5719;method_43695()Znamed triggersAvoidCriterionLnet/minecraft/world/event/listener/VibrationListener$Callback;triggersAvoidCriterion()Z
-
accepts
public boolean accepts(ServerWorld world, GameEventListener listener, BlockPos pos, GameEvent event, @Nullable GameEvent.Emitter emitter) Returns whether the callback wants to accept this event.- Specified by:
acceptsin interfaceVibrationListener.Callback- Mappings:
Namespace Name Mixin selector official aLdab$b;a(Lagg;Lczx;Lgt;Lczv;Lczv$a;)Zintermediary method_32970Lnet/minecraft/class_5718$class_5719;method_32970(Lnet/minecraft/class_3218;Lnet/minecraft/class_5714;Lnet/minecraft/class_2338;Lnet/minecraft/class_5712;Lnet/minecraft/class_5712$class_7397;)Znamed acceptsLnet/minecraft/world/event/listener/VibrationListener$Callback;accepts(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/event/listener/GameEventListener;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/world/event/GameEvent;Lnet/minecraft/world/event/GameEvent$Emitter;)Z
-
accept
public void accept(ServerWorld world, GameEventListener listener, BlockPos pos, GameEvent event, @Nullable @Nullable Entity entity, @Nullable @Nullable Entity sourceEntity, float distance) Accepts a game event after delay.- Specified by:
acceptin interfaceVibrationListener.Callback- Mappings:
Namespace Name Mixin selector official aLdab$b;a(Lagg;Lczx;Lgt;Lczv;Lbbn;Lbbn;F)Vintermediary method_32969Lnet/minecraft/class_5718$class_5719;method_32969(Lnet/minecraft/class_3218;Lnet/minecraft/class_5714;Lnet/minecraft/class_2338;Lnet/minecraft/class_5712;Lnet/minecraft/class_1297;Lnet/minecraft/class_1297;F)Vnamed acceptLnet/minecraft/world/event/listener/VibrationListener$Callback;accept(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/event/listener/GameEventListener;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/world/event/GameEvent;Lnet/minecraft/entity/Entity;Lnet/minecraft/entity/Entity;F)V
-
onListen
public void onListen()- Specified by:
onListenin interfaceVibrationListener.Callback- Mappings:
Namespace Name Mixin selector official fLdab$b;f()Vintermediary method_42672Lnet/minecraft/class_5718$class_5719;method_42672()Vnamed onListenLnet/minecraft/world/event/listener/VibrationListener$Callback;onListen()V
-
getPower
public static int getPower(float distance, int range) - Mappings:
Namespace Name Mixin selector official aLcuh;a(FI)Iintermediary method_32910Lnet/minecraft/class_5704;method_32910(FI)Inamed getPowerLnet/minecraft/block/entity/SculkSensorBlockEntity;getPower(FI)I
-
setLastVibrationFrequency
public void setLastVibrationFrequency(int lastVibrationFrequency) - Mappings:
Namespace Name Mixin selector official aLcuh;a(I)Vintermediary method_44213Lnet/minecraft/class_5704;method_44213(I)Vnamed setLastVibrationFrequencyLnet/minecraft/block/entity/SculkSensorBlockEntity;setLastVibrationFrequency(I)V
-