A class for constructing 2D walls for wall avoidance behaviors. More...
#include <Wall.hpp>
Public Member Functions | |
Wall () | |
Default constructor. | |
Wall (bool render, Vector2 A, Vector2 B) | |
Alternative constructor. | |
Wall (bool render, Vector2 A, Vector2 B, Vector2 N) | |
Alternative constructor. | |
bool | renderNormal () const |
Returns a bool indicating if the normal should be rendered. | |
void | toggleRenderNormal () |
Toggles the bool indicating if the normal should be rendered. | |
Vector2 | From () const |
Returns the "from" vector component of the wall. | |
void | SetFrom (Vector2 v) |
Sets the "from" vector component of the wall. | |
Vector2 | To () const |
Returns the "to" vector component of the wall. | |
void | SetTo (Vector2 v) |
Sets the "to" vector component of the wall. | |
Vector2 | Normal () const |
Returns the "normal" vector component of the wall. | |
void | SetNormal (Vector2 n) |
Sets the "normal" vector component of the wall. | |
Vector2 | Center () const |
Returns the "center" vector component of the wall. | |
A class for constructing 2D walls for wall avoidance behaviors.
void steer::Wall::SetFrom | ( | Vector2 | v | ) |
Sets the "from" vector component of the wall.
v | - a Vector2. |
void steer::Wall::SetNormal | ( | Vector2 | n | ) |
Sets the "normal" vector component of the wall.
v | - a Vector2. |
void steer::Wall::SetTo | ( | Vector2 | v | ) |
Sets the "to" vector component of the wall.
v | - a Vector2. |