MazeAI / MazeAIRunner
Namespace
Playniax.MazeAIInherits from
MazeAISpriteScript can be found in
Assets/Playniax/Framework/MazeAI/Scripts (MonoBehaviour)/MazeAIRunner.cs
Class MazeAIRunner
DescriptionBase class for maze sprites. The sprite will display a Pacman ghost-like behaviour.
Public fields | Description |
---|
Direction startDirection = Direction.Right | Start direction. |
bool borderControl | When enabled the sprite will exit the screen on one side but reappear on the other. Note that the tilemap should allow it. |
Public Methods | Description |
---|
virtual bool IsObstacle(Tilemap tilemap, Vector3 position, Vector3[] contactPoints, int contactPoint) | Returns whether a tile in the tilemap is an obstacle or not. |
virtual void OnSetDirection(Vector3 direction) | OnSetDirection is called when the sprite changes direction. Implement OnSetDirection if you for example want the sprite to face the correct direction. |