Class PathfinderHurtByTarget

All Implemented Interfaces:
PathfinderInfo, Targeting

public final class PathfinderHurtByTarget extends TargetPathfinder
Represents a Pathfinder for any Creature to retaliate if they are damaged
  • Constructor Details

    • PathfinderHurtByTarget

      public PathfinderHurtByTarget(@NotNull @NotNull Creature c, EntityType... ignore)
      Constructs a PathfinderHurtByTarget.
      Parameters:
      c - Creature to use
      ignore - EntityTypes to ignore when hurt
  • Method Details

    • getIgnoring

      @NotNull public @NotNull List<EntityType> getIgnoring()
      Gets the current list of EntityTypes to ignore when hurt.
      Returns:
      List of Entity Types to ignore when hurt.
    • setIgnoring

      public void setIgnoring(@NotNull @NotNull EntityType... ignoring)
      Sets the current list of EntityTypes to ignore when hurt.
      Parameters:
      ignoring - Array of EntityTypes to ignore when hurt.
    • addIgnore

      public void addIgnore(@NotNull @NotNull EntityType t)
      Adds an EntityType to the List of EntityTypes to ignore when hurt.
      Parameters:
      t - EntityType to add
    • removeIgnore

      public void removeIgnore(@NotNull @NotNull EntityType t)
      Removes an EntityType from the List of EntityTypes to ignore when hurt.
      Parameters:
      t - EntityType to remove
    • getFlags

      Description copied from class: Pathfinder

      Fetches an Array of Flags that this Pathfinder has.

      Specified by:
      getFlags in class Pathfinder
      Returns:
      Array of Pathfinder Flags
    • getInternalName

      public String getInternalName()
      Description copied from interface: PathfinderInfo
      Returns the NMS Internal Name.
      Returns:
      Internal Name