Class HeadMotionObserve
java.lang.Object
com.hypixel.hytale.server.npc.corecomponents.AnnotatedComponentBase
com.hypixel.hytale.server.npc.corecomponents.MotionBase
com.hypixel.hytale.server.npc.corecomponents.HeadMotionBase
com.hypixel.hytale.server.npc.corecomponents.world.HeadMotionObserve
- All Implemented Interfaces:
HeadMotion,Motion,RoleStateChange,IAnnotatedComponent
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final float[]protected intprotected doubleprotected booleanprotected final double[]protected final booleanprotected doubleprotected final doubleprotected final SteeringForceRotateprotected floatprotected final intFields inherited from class com.hypixel.hytale.server.npc.corecomponents.AnnotatedComponentBase
index, parent -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidactivate(Ref<EntityStore> ref, Role role, ComponentAccessor<EntityStore> componentAccessor) booleancomputeSteering(Ref<EntityStore> ref, Role role, InfoProvider sensorInfo, double dt, Steering desiredSteering, ComponentAccessor<EntityStore> componentAccessor) protected voidpickNextAngle(Ref<EntityStore> ref, ComponentAccessor<EntityStore> componentAccessor) protected booleantickDelay(double dt) protected booleantickPreDelay(double dt) Methods inherited from class com.hypixel.hytale.server.npc.corecomponents.AnnotatedComponentBase
getIndex, getInfo, getParent, setContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.hypixel.hytale.server.npc.util.IAnnotatedComponent
getBreadCrumbs, getBreadCrumbs, getIndex, getInfo, getLabel, getParent, setContextMethods inherited from interface com.hypixel.hytale.server.npc.instructions.Motion
deactivate, preComputeSteeringMethods inherited from interface com.hypixel.hytale.server.npc.instructions.RoleStateChange
loaded, motionControllerChanged, registerWithSupport, removed, spawned, teleported, unloaded
-
Field Details
-
angleRange
protected final float[] angleRange -
pauseTimeRange
protected final double[] pauseTimeRange -
pickRandomAngle
protected final boolean pickRandomAngle -
viewSegments
protected final int viewSegments -
relativeTurnSpeed
protected final double relativeTurnSpeed -
preDelay
protected double preDelay -
delay
protected double delay -
currentViewSegment
protected int currentViewSegment -
invertedDirection
protected boolean invertedDirection -
targetBodyOffsetYaw
protected float targetBodyOffsetYaw -
steeringForceRotate
-
-
Constructor Details
-
HeadMotionObserve
public HeadMotionObserve(@Nonnull BuilderHeadMotionObserve builder, @Nonnull BuilderSupport support)
-
-
Method Details
-
activate
public void activate(@Nonnull Ref<EntityStore> ref, @Nonnull Role role, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
computeSteering
public boolean computeSteering(@Nonnull Ref<EntityStore> ref, @Nonnull Role role, @Nullable InfoProvider sensorInfo, double dt, @Nonnull Steering desiredSteering, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
tickPreDelay
protected boolean tickPreDelay(double dt) -
tickDelay
protected boolean tickDelay(double dt) -
pickNextAngle
protected void pickNextAngle(@Nonnull Ref<EntityStore> ref, @Nonnull ComponentAccessor<EntityStore> componentAccessor)
-