Interface
PatrolComp
:waypoints
: Vec2[] | undefinedPath to follow. If null, doesn't move.
patrolSpeed
: numberSpeed of the movement during patrol.
nextLocation
: Vec2 | undefinedCurrent subgoal, if any.
onPatrolFinished
(cb: (objects: GameObj[]) => void): KEventControllerAttaches an event handler which is called when using "stop" and the end of the path is reached.
param
cb- The event handler called when the patrol finishes.