Class BodyMotionPath
java.lang.Object
com.hypixel.hytale.server.npc.corecomponents.AnnotatedComponentBase
com.hypixel.hytale.server.npc.corecomponents.MotionBase
com.hypixel.hytale.server.npc.corecomponents.BodyMotionBase
com.hypixel.hytale.server.npc.corecomponents.world.BodyMotionPath
- All Implemented Interfaces:
BodyMotion,Motion,RoleStateChange,IAnnotatedComponent
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enum -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected BodyMotionPath.Directionprotected doubleprotected doubleprotected final Vector3dprotected doubleprotected intprotected intprotected final Vector3dprotected final BodyMotionPath.Directionprotected final Vector3dprotected final doubleprotected final doubleprotected final doubleprotected final doubleprotected final doublestatic final doubleprotected final doubleprotected final doubleprotected final doubleprotected final doubleprotected final doubleprotected final Vector3dprotected booleanprotected floatprotected doubleprotected final doubleprotected floatprotected final doubleprotected booleanprotected final booleanprotected final Vector3dprotected booleanprotected booleanprotected final BodyMotionPath.Shapeprotected final booleanprotected final SteeringForcePursueprotected final SteeringForceRotatestatic final booleanprotected final booleanprotected final intprotected intprotected final it.unimi.dsi.fastutil.ints.IntListFields 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) protected booleancloseToPosition(Vector3d position, com.hypixel.hytale.server.npc.movement.controllers.MotionController motionController) booleancomputeSteering(Ref<EntityStore> ref, Role role, InfoProvider sensorInfo, double dt, Steering desiredSteering, ComponentAccessor<EntityStore> componentAccessor) protected booleangetFirstWaypoint(Ref<EntityStore> ref, Role role, IPath<?> path, Vector3d lastPos, ComponentAccessor<EntityStore> componentAccessor) protected voidprotected voidvoidprotected booleannextWayPoint(IPath<?> path, WorldSupport support, ComponentAccessor<EntityStore> componentAccessor) protected voidprotected voidreset()protected booleantickObservationDelay(double dt) protected voidwaypointIndexUpdated(IPath<?> path, ComponentAccessor<EntityStore> componentAccessor) 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.instructions.BodyMotion
getSteeringMotionMethods 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
motionControllerChanged, registerWithSupport, removed, spawned, teleported, unloaded
-
Field Details
-
MIN_GUARD_POINT_WAIT_TIME
public static final double MIN_GUARD_POINT_WAIT_TIME- See Also:
-
TESTING
public static final boolean TESTING- See Also:
-
shape
-
pathWidth
protected final double pathWidth -
nodeWidth
protected final double nodeWidth -
minRelativeSpeed
protected final double minRelativeSpeed -
maxRelativeSpeed
protected final double maxRelativeSpeed -
minWalkDistance
protected final double minWalkDistance -
maxWalkDistance
protected final double maxWalkDistance -
startAtNearestNode
protected final boolean startAtNearestNode -
direction
-
minNodeDelay
protected final double minNodeDelay -
maxNodeDelay
protected final double maxNodeDelay -
viewSegments
protected final int viewSegments -
useNodeViewDirection
protected final boolean useNodeViewDirection -
pickRandomAngle
protected final boolean pickRandomAngle -
minDelayScale
protected final double minDelayScale -
maxDelayScale
protected final double maxDelayScale -
minPercentage
protected final double minPercentage -
maxPercentage
protected final double maxPercentage -
currentWaypointIndex
protected int currentWaypointIndex -
currentDirection
-
currentWaypointPosition
-
lastWaypointPosition
-
visitOrder
protected final it.unimi.dsi.fastutil.ints.IntList visitOrder -
visitIndex
protected int visitIndex -
steeringForceRotate
-
steeringForcePursue
-
currentSpeed
protected double currentSpeed -
currentPosition
-
nextPosition
-
nextPositionValid
protected boolean nextPositionValid -
currentNodeDelay
protected double currentNodeDelay -
pendingNodeDelay
protected boolean pendingNodeDelay -
rotatingToView
protected boolean rotatingToView -
nodeViewDirection
protected float nodeViewDirection -
nodeWaitTime
protected double nodeWaitTime -
observationSector
protected float observationSector -
currentObservationDelay
protected double currentObservationDelay -
rotating
protected boolean rotating -
previousSteeringTranslation
-
currentViewSegment
protected int currentViewSegment
-
-
Constructor Details
-
BodyMotionPath
-
-
Method Details
-
activate
public void activate(@Nonnull Ref<EntityStore> ref, @Nonnull Role role, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
loaded
-
computeSteering
public boolean computeSteering(@Nonnull Ref<EntityStore> ref, @Nonnull Role role, @Nullable InfoProvider sensorInfo, double dt, @Nonnull Steering desiredSteering, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
tickObservationDelay
protected boolean tickObservationDelay(double dt) -
pickNextObservationAngle
protected void pickNextObservationAngle() -
closeToPosition
protected boolean closeToPosition(Vector3d position, @Nonnull com.hypixel.hytale.server.npc.movement.controllers.MotionController motionController) -
invalidateWaypoint
protected void invalidateWaypoint() -
nextWayPoint
protected boolean nextWayPoint(@Nonnull IPath<?> path, @Nonnull WorldSupport support, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
getFirstWaypoint
protected boolean getFirstWaypoint(@Nonnull Ref<EntityStore> ref, @Nonnull Role role, @Nullable IPath<?> path, @Nonnull Vector3d lastPos, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
waypointIndexUpdated
protected void waypointIndexUpdated(@Nonnull IPath<?> path, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
initializeCurrentDirection
protected void initializeCurrentDirection() -
reset
protected void reset()
-