public abstract class PathfinderAbstract<N extends NPCAbstract<?,?>> extends AIAbstract<N>
Modifier and Type | Field and Description |
---|---|
protected boolean |
finished |
protected double |
progress |
protected double |
speed |
protected org.inventivetalent.vectors.d3.Vector3DDouble |
target |
Constructor and Description |
---|
PathfinderAbstract(org.inventivetalent.vectors.d3.Vector3DDouble target,
double speed) |
Modifier and Type | Method and Description |
---|---|
void |
find() |
protected abstract NMSPathEntity |
findPath() |
org.inventivetalent.vectors.d3.Vector3DDouble |
getNpcVector() |
org.bukkit.World |
getNpcWorld() |
org.inventivetalent.vectors.d3.Vector3DDouble |
getTarget() |
boolean |
isFinished()
If this returns
true , this AI will be removed from the NPC |
void |
tick()
Called when the containing NPC is ticked
|
getNpc, setNpc
protected final org.inventivetalent.vectors.d3.Vector3DDouble target
protected final double speed
protected boolean finished
protected double progress
public PathfinderAbstract(org.inventivetalent.vectors.d3.Vector3DDouble target, double speed)
public void tick()
AIAbstract
tick
in class AIAbstract<N extends NPCAbstract<?,?>>
public void find()
protected abstract NMSPathEntity findPath()
public boolean isFinished()
AIAbstract
true
, this AI will be removed from the NPCisFinished
in class AIAbstract<N extends NPCAbstract<?,?>>
true
, the AI will be removedpublic org.bukkit.World getNpcWorld()
public org.inventivetalent.vectors.d3.Vector3DDouble getNpcVector()
public org.inventivetalent.vectors.d3.Vector3DDouble getTarget()
Copyright © 2018. All rights reserved.