onSpotted uses now Pathfinding to check if there is a way
onUnreachable will now also check for timeout if there is no path
StateMachine history will be cleaned if it gets to full