A* Pathfinding Project
4.0.3
The A* Pathfinding Project for Unity 3D
|
Square Obstacle for RVO Simulation. More...
Square Obstacle for RVO Simulation.
Public Attributes | |
Vector2 | center = Vector3.zero |
Center of the square. | |
float | height = 1 |
Height of the obstacle. | |
Vector2 | size = Vector3.one |
Size of the square. | |
![]() | |
RVOLayer | layer = RVOLayer.DefaultObstacle |
ObstacleVertexWinding | obstacleMode |
Mode of the obstacle. | |
Protected Member Functions | |
override bool | AreGizmosDirty () |
Called in the editor. | |
override void | CreateObstacles () |
Create Obstacles. | |
![]() | |
void | AddObstacle (Vector3[] vertices, float height) |
Adds an obstacle with the specified vertices. | |
void | FindSimulator () |
Finds a simulator in the scene. | |
virtual Matrix4x4 | GetMatrix () |
Get's the matrix to use for vertices. | |
![]() | |
virtual void | Awake () |
virtual int | OnUpgradeSerializedData (int version) |
Handle serialization backwards compatibility. | |
Properties | |
override bool | ExecuteInEditor [get] |
override float | Height [get] |
override bool | LocalCoordinates [get] |
override bool | StaticObstacle [get] |
![]() | |
abstract bool | ExecuteInEditor [get] |
Enable executing in editor to draw gizmos. | |
abstract float | Height [get] |
abstract bool | LocalCoordinates [get] |
If enabled, all coordinates are handled as local. | |
abstract bool | StaticObstacle [get] |
Static or dynamic. | |
Additional Inherited Members | |
![]() | |
enum | ObstacleVertexWinding { KeepOut, KeepIn } |
RVO Obstacle Modes. More... | |
![]() | |
void | OnDisable () |
Disables the obstacle. | |
void | OnDrawGizmos () |
Draws Gizmos. | |
void | OnDrawGizmos (bool selected) |
Draws Gizmos. | |
void | OnDrawGizmosSelected () |
Draws Gizmos. | |
void | OnEnable () |
Enabled the obstacle. | |
void | Start () |
Creates obstacles. | |
void | Update () |
Updates obstacle if required. | |
![]() | |
Pathfinding.RVO.Simulator | sim |
Reference to simulator. | |
|
protectedvirtual |
Called in the editor.
This function should return true if any variables which can change the shape or position of the obstacle has changed since the last call to this function. Take a look at the RVOSquareObstacle for an example.
Implements RVOObstacle.
|
protectedvirtual |
Create Obstacles.
Override this and add logic for creating obstacles. You should not use the simulator's function calls directly.
Implements RVOObstacle.
Vector2 center = Vector3.zero |
Center of the square.
float height = 1 |
Height of the obstacle.
Vector2 size = Vector3.one |
Size of the square.
|
getprotected |
|
getprotected |
|
getprotected |
|
getprotected |