Rectangle collider class. More...
#include <RectangleCollider.h>
Public Member Functions | |
| RectangleCollider () | |
| RectangleCollider (CIwFVec2 position, CIwFVec2 dimensions) | |
| ~RectangleCollider () | |
| float | GetLeft () |
| float | GetRight () |
| float | GetCentre () |
| float | GetTop () |
| float | GetWidth () |
Protected Attributes | |
| CIwFVec2 | m_position |
| Position of collider. | |
| CIwFVec2 | m_dimensions |
| Collider dimensions (in pixels). | |
Rectangle collider class.
Rectangular physics object for use inside the grid to separate columns.
| RectangleCollider::RectangleCollider | ( | ) | [inline] |
Default constructor.
Create a new rectangle collider.
| RectangleCollider::RectangleCollider | ( | CIwFVec2 | position, | |
| CIwFVec2 | dimensions | |||
| ) |
Constructor.
Create a new rectangle collider.
| [in] | position | Position of the collider. |
| [in] | dimensions | Pixel dimensions of the collider. |
| RectangleCollider::~RectangleCollider | ( | ) | [inline] |
Destructor.
Destroy the collider.
| float RectangleCollider::GetCentre | ( | ) |
Get centre.
Get the x position of the centre of the collider.
| float RectangleCollider::GetLeft | ( | ) |
Get left.
Get the x position of the left hand side of the collider.
| float RectangleCollider::GetRight | ( | ) |
Get right.
Get the x position of the right hand side of the collider.
| float RectangleCollider::GetTop | ( | ) |
Get top.
Get the y position of the top of the collider.
| float RectangleCollider::GetWidth | ( | ) |
Get width.
Get the width of the collider.
1.7.1