Class PathfinderAddEvent
java.lang.Object
org.bukkit.event.Event
me.gamercoder215.mobchip.bukkit.events.pathfinder.PathfinderEvent
me.gamercoder215.mobchip.bukkit.events.pathfinder.PathfinderAddEvent
- All Implemented Interfaces:
Cancellable
Called before a Pathfinder is added
-
Nested Class Summary
Nested classes/interfaces inherited from class Event
Event.Result -
Constructor Summary
ConstructorsConstructorDescriptionPathfinderAddEvent(@NotNull EntityAI ai, @NotNull Pathfinder p, boolean target, int priority) Constructs a PathfinderAddEvent. -
Method Summary
Modifier and TypeMethodDescriptionintGets the priority that this Pathfinder will be added to.booleanvoidsetCancelled(boolean cancel) Methods inherited from class PathfinderEvent
getAI, getHandlerList, getHandlers, getPathfinder, isTargetMethods inherited from class Event
getEventName, isAsynchronous
-
Constructor Details
-
PathfinderAddEvent
public PathfinderAddEvent(@NotNull @NotNull EntityAI ai, @NotNull @NotNull Pathfinder p, boolean target, int priority) Constructs a PathfinderAddEvent.- Parameters:
ai- EntityAI usedp- Pathfinder usedtarget- Whether AI is Target AIpriority- Priority of Pathfinder
-
-
Method Details
-
getPriority
public int getPriority()Gets the priority that this Pathfinder will be added to.- Returns:
- Priority added
-
isCancelled
public boolean isCancelled()- Specified by:
isCancelledin interfaceCancellable
-
setCancelled
public void setCancelled(boolean cancel) - Specified by:
setCancelledin interfaceCancellable
-