Interface

PatrolComp

:

waypoints

: Vec2[] | undefined

patrolSpeed

: number

nextLocation

: Vec2 | undefined

onPatrolFinished

(cb: (objects: GameObj[]) => void): KEventController

Attaches an event handler which is called when using "stop" and the end of the path is reached.

param cbThe event handler called when the patrol finishes.