Class StateEvaluator

java.lang.Object
com.hypixel.hytale.server.npc.decisionmaker.core.Evaluator<StateOption>
com.hypixel.hytale.server.npc.decisionmaker.stateevaluator.StateEvaluator
All Implemented Interfaces:
Component<EntityStore>, Cloneable

public class StateEvaluator extends Evaluator<StateOption> implements Component<EntityStore>
An implementation of the Evaluator designed to dynamically switch NPC states.
Since:
2019/12/11
  • Field Details

  • Method Details

    • getComponentType

      public static ComponentType<EntityStore, StateEvaluator> getComponentType()
    • isActive

      public boolean isActive()
    • setActive

      public void setActive(boolean active)
    • getEvaluationContext

      @Nonnull public EvaluationContext getEvaluationContext()
    • prepareOptions

      public void prepareOptions(@Nonnull StateMappingHelper stateHelper)
    • shouldExecute

      public boolean shouldExecute(double interval)
    • prepareEvaluationContext

      public void prepareEvaluationContext(@Nonnull EvaluationContext context)
    • onStateSwitched

      public void onStateSwitched()
    • toString

      @Nonnull public String toString()
      Overrides:
      toString in class Object
    • clone

      @Nonnull public Component<EntityStore> clone()
      Specified by:
      clone in interface Component<EntityStore>
      Returns:
      a clone instance of the original component instance.