Class VibrationListener
java.lang.Object
net.minecraft.world.event.listener.VibrationListener
- All Implemented Interfaces:
GameEventListener
- Mappings:
Namespace Name official dkzintermediary net/minecraft/class_5718named net/minecraft/world/event/listener/VibrationListener
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minecraft.world.event.listener.GameEventListener
GameEventListener.TriggerOrder -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final VibrationListener.Callbackprivate intstatic final Object2IntMap<GameEvent>private final PositionSourcestatic final GameEvent[]private final VibrationSelector -
Constructor Summary
ConstructorsModifierConstructorDescriptionVibrationListener(PositionSource positionSource, VibrationListener.Callback callback) privateVibrationListener(PositionSource positionSource, VibrationListener.Callback callback, @Nullable Vibration vibration, VibrationSelector selector, int delay) -
Method Summary
Modifier and TypeMethodDescriptionstatic com.mojang.serialization.Codec<VibrationListener>createCodec(VibrationListener.Callback callback) voidforceListen(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos) static intgetFrequency(GameEvent event) Returns the position source of this listener.intgetRange()Returns the range, in blocks, of the listener.static GameEventgetResonation(int frequency) private static booleanisOccluded(World world, Vec3d start, Vec3d end) booleanlisten(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos) Listens to an incoming game event.voidvoidtrySelect(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos, Vec3d listenerPos) Methods 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.GameEventListener
getTriggerOrder
-
Field Details
-
RESONATIONS
- Mappings:
Namespace Name Mixin selector official aLdkz;a:[Ldkr;intermediary field_43323Lnet/minecraft/class_5718;field_43323:[Lnet/minecraft/class_5712;named RESONATIONSLnet/minecraft/world/event/listener/VibrationListener;RESONATIONS:[Lnet/minecraft/world/event/GameEvent;
-
FREQUENCIES
- Mappings:
Namespace Name Mixin selector official bLdkz;b:Lit/unimi/dsi/fastutil/objects/Object2IntMap;intermediary field_40356Lnet/minecraft/class_5718;field_40356:Lit/unimi/dsi/fastutil/objects/Object2IntMap;named FREQUENCIESLnet/minecraft/world/event/listener/VibrationListener;FREQUENCIES:Lit/unimi/dsi/fastutil/objects/Object2IntMap;
-
positionSource
- Mappings:
Namespace Name Mixin selector official cLdkz;c:Ldkv;intermediary field_28187Lnet/minecraft/class_5718;field_28187:Lnet/minecraft/class_5716;named positionSourceLnet/minecraft/world/event/listener/VibrationListener;positionSource:Lnet/minecraft/world/event/PositionSource;
-
callback
- Mappings:
Namespace Name Mixin selector official dLdkz;d:Ldkz$a;intermediary field_28189Lnet/minecraft/class_5718;field_28189:Lnet/minecraft/class_5718$class_5719;named callbackLnet/minecraft/world/event/listener/VibrationListener;callback:Lnet/minecraft/world/event/listener/VibrationListener$Callback;
-
vibration
- Mappings:
Namespace Name Mixin selector official eLdkz;e:Ldky;intermediary field_40357Lnet/minecraft/class_5718;field_40357:Lnet/minecraft/class_7269;named vibrationLnet/minecraft/world/event/listener/VibrationListener;vibration:Lnet/minecraft/world/event/listener/Vibration;
-
delay
private int delay- Mappings:
Namespace Name Mixin selector official fLdkz;f:Iintermediary field_28192Lnet/minecraft/class_5718;field_28192:Inamed delayLnet/minecraft/world/event/listener/VibrationListener;delay:I
-
selector
- Mappings:
Namespace Name Mixin selector official gLdkz;g:Ldla;intermediary field_40358Lnet/minecraft/class_5718;field_40358:Lnet/minecraft/class_7722;named selectorLnet/minecraft/world/event/listener/VibrationListener;selector:Lnet/minecraft/world/event/listener/VibrationSelector;
-
-
Constructor Details
-
VibrationListener
private VibrationListener(PositionSource positionSource, VibrationListener.Callback callback, @Nullable @Nullable Vibration vibration, VibrationSelector selector, int delay) - Mappings:
Namespace Name Mixin selector official <init>Ldkz;<init>(Ldkv;Ldkz$a;Ldky;Ldla;I)Vintermediary <init>Lnet/minecraft/class_5718;<init>(Lnet/minecraft/class_5716;Lnet/minecraft/class_5718$class_5719;Lnet/minecraft/class_7269;Lnet/minecraft/class_7722;I)Vnamed <init>Lnet/minecraft/world/event/listener/VibrationListener;<init>(Lnet/minecraft/world/event/PositionSource;Lnet/minecraft/world/event/listener/VibrationListener$Callback;Lnet/minecraft/world/event/listener/Vibration;Lnet/minecraft/world/event/listener/VibrationSelector;I)V
-
VibrationListener
- Mappings:
Namespace Name Mixin selector official <init>Ldkz;<init>(Ldkv;Ldkz$a;)Vintermediary <init>Lnet/minecraft/class_5718;<init>(Lnet/minecraft/class_5716;Lnet/minecraft/class_5718$class_5719;)Vnamed <init>Lnet/minecraft/world/event/listener/VibrationListener;<init>(Lnet/minecraft/world/event/PositionSource;Lnet/minecraft/world/event/listener/VibrationListener$Callback;)V
-
-
Method Details
-
createCodec
public static com.mojang.serialization.Codec<VibrationListener> createCodec(VibrationListener.Callback callback) - Mappings:
Namespace Name Mixin selector official aLdkz;a(Ldkz$a;)Lcom/mojang/serialization/Codec;intermediary method_42340Lnet/minecraft/class_5718;method_42340(Lnet/minecraft/class_5718$class_5719;)Lcom/mojang/serialization/Codec;named createCodecLnet/minecraft/world/event/listener/VibrationListener;createCodec(Lnet/minecraft/world/event/listener/VibrationListener$Callback;)Lcom/mojang/serialization/Codec;
-
getFrequency
- Mappings:
Namespace Name Mixin selector official aLdkz;a(Ldkr;)Iintermediary method_45496Lnet/minecraft/class_5718;method_45496(Lnet/minecraft/class_5712;)Inamed getFrequencyLnet/minecraft/world/event/listener/VibrationListener;getFrequency(Lnet/minecraft/world/event/GameEvent;)I
-
getResonation
- Mappings:
Namespace Name Mixin selector official aLdkz;a(I)Ldkr;intermediary method_49881Lnet/minecraft/class_5718;method_49881(I)Lnet/minecraft/class_5712;named getResonationLnet/minecraft/world/event/listener/VibrationListener;getResonation(I)Lnet/minecraft/world/event/GameEvent;
-
getCallback
- Mappings:
Namespace Name Mixin selector official dLdkz;d()Ldkz$a;intermediary method_49882Lnet/minecraft/class_5718;method_49882()Lnet/minecraft/class_5718$class_5719;named getCallbackLnet/minecraft/world/event/listener/VibrationListener;getCallback()Lnet/minecraft/world/event/listener/VibrationListener$Callback;
-
tick
- Mappings:
Namespace Name Mixin selector official aLdkz;a(Lcql;)Vintermediary method_32964Lnet/minecraft/class_5718;method_32964(Lnet/minecraft/class_1937;)Vnamed tickLnet/minecraft/world/event/listener/VibrationListener;tick(Lnet/minecraft/world/World;)V
-
getPositionSource
Returns the position source of this listener.- Specified by:
getPositionSourcein interfaceGameEventListener- Mappings:
Namespace Name Mixin selector official aLdkt;a()Ldkv;intermediary method_32946Lnet/minecraft/class_5714;method_32946()Lnet/minecraft/class_5716;named getPositionSourceLnet/minecraft/world/event/listener/GameEventListener;getPositionSource()Lnet/minecraft/world/event/PositionSource;
-
getRange
public int getRange()Returns the range, in blocks, of the listener.- Specified by:
getRangein interfaceGameEventListener- Mappings:
Namespace Name Mixin selector official bLdkt;b()Iintermediary method_32948Lnet/minecraft/class_5714;method_32948()Inamed getRangeLnet/minecraft/world/event/listener/GameEventListener;getRange()I
-
listen
public boolean listen(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos) Listens to an incoming game event.- Specified by:
listenin interfaceGameEventListener- Returns:
trueif the game event has been accepted by this listener- Mappings:
Namespace Name Mixin selector official aLdkt;a(Laik;Ldkr;Ldkr$a;Leii;)Zintermediary method_32947Lnet/minecraft/class_5714;method_32947(Lnet/minecraft/class_3218;Lnet/minecraft/class_5712;Lnet/minecraft/class_5712$class_7397;Lnet/minecraft/class_243;)Znamed listenLnet/minecraft/world/event/listener/GameEventListener;listen(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/event/GameEvent;Lnet/minecraft/world/event/GameEvent$Emitter;Lnet/minecraft/util/math/Vec3d;)Z
-
forceListen
public void forceListen(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos) - Mappings:
Namespace Name Mixin selector official bLdkz;b(Laik;Ldkr;Ldkr$a;Leii;)Vintermediary method_45498Lnet/minecraft/class_5718;method_45498(Lnet/minecraft/class_3218;Lnet/minecraft/class_5712;Lnet/minecraft/class_5712$class_7397;Lnet/minecraft/class_243;)Vnamed forceListenLnet/minecraft/world/event/listener/VibrationListener;forceListen(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/event/GameEvent;Lnet/minecraft/world/event/GameEvent$Emitter;Lnet/minecraft/util/math/Vec3d;)V
-
trySelect
public void trySelect(ServerWorld world, GameEvent event, GameEvent.Emitter emitter, Vec3d emitterPos, Vec3d listenerPos) - Mappings:
Namespace Name Mixin selector official aLdkz;a(Laik;Ldkr;Ldkr$a;Leii;Leii;)Vintermediary method_45494Lnet/minecraft/class_5718;method_45494(Lnet/minecraft/class_3218;Lnet/minecraft/class_5712;Lnet/minecraft/class_5712$class_7397;Lnet/minecraft/class_243;Lnet/minecraft/class_243;)Vnamed trySelectLnet/minecraft/world/event/listener/VibrationListener;trySelect(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/event/GameEvent;Lnet/minecraft/world/event/GameEvent$Emitter;Lnet/minecraft/util/math/Vec3d;Lnet/minecraft/util/math/Vec3d;)V
-
isOccluded
- Mappings:
Namespace Name Mixin selector official aLdkz;a(Lcql;Leii;Leii;)Zintermediary method_32966Lnet/minecraft/class_5718;method_32966(Lnet/minecraft/class_1937;Lnet/minecraft/class_243;Lnet/minecraft/class_243;)Znamed isOccludedLnet/minecraft/world/event/listener/VibrationListener;isOccluded(Lnet/minecraft/world/World;Lnet/minecraft/util/math/Vec3d;Lnet/minecraft/util/math/Vec3d;)Z
-