Contents
Class SensorBase
java.lang.Object
com.hypixel.hytale.server.npc.corecomponents.AnnotatedComponentBase
com.hypixel.hytale.server.npc.corecomponents.SensorBase
- All Implemented Interfaces:
RoleStateChange, Sensor, IAnnotatedComponent, IComponentExecutionControl
- Direct Known Subclasses:
SensorAge, SensorAlarm, SensorAnimation, SensorAny, SensorBeacon, SensorBlock, SensorBlockType, SensorCanInteract, SensorCanPlace, SensorChargeBlockCollisions, SensorChargeEntityCollisions, SensorChargeState, SensorCombatActionEvaluator, SensorCount, SensorDamage, SensorDroppedItem, SensorEval, SensorEvent, SensorFlag, SensorFlockCombatDamage, SensorFlockLeader, SensorGameFlag, SensorHasHostileTargetMemory, SensorHasInteracted, SensorHasTask, SensorInAir, SensorInflictedDamage, SensorInteractionContext, SensorInWater, SensorIsBackingAway, SensorIsBusy, SensorKill, SensorLeash, SensorLight, SensorMany, SensorMotionController, SensorNav, SensorNot, SensorOnGround, SensorPath, SensorPoints, SensorRandom, SensorReadPosition, SensorSearchRay, SensorState, SensorSwitch, SensorTime, SensorTimer, SensorTransformBase, SensorValueProviderWrapper, SensorWeather, SensorWithEntityFilters
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanbooleanmatches(Ref<EntityStore> ref, ExecutionSupport executionSupport, double dt, Store<EntityStore> store) booleanprocessDelay(float dt) Tick down the internal delay on this core componentvoidsetOnce()Methods inherited from class AnnotatedComponentBase
getIndex, getInfo, getParent, setContextMethods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface IAnnotatedComponent
getBreadCrumbs, getBreadCrumbs, getIndex, getInfo, getLabel, getParent, setContextMethods inherited from interface RoleStateChange
loaded, motionControllerChanged, registerWithSupport, removed, spawned, teleported, unloadedMethods inherited from interface Sensor
done, getSensorInfo
-
Constructor Details
-
SensorBase
-
-
Method Details
-
matches
public boolean matches(@Nonnull Ref<EntityStore> ref, @Nonnull ExecutionSupport executionSupport, double dt, @Nonnull Store<EntityStore> store) -
clearOnce
public void clearOnce()- Specified by:
clearOncein interfaceIComponentExecutionControl
-
setOnce
public void setOnce()- Specified by:
setOncein interfaceIComponentExecutionControl
-
isTriggered
public boolean isTriggered()- Specified by:
isTriggeredin interfaceIComponentExecutionControl
-
processDelay
public boolean processDelay(float dt) Description copied from interface:IComponentExecutionControlTick down the internal delay on this core component- Specified by:
processDelayin interfaceIComponentExecutionControl- Parameters:
dt- the tick duration- Returns:
- whether this component has finished processing its internal delay
-