Creates a Vec2 structure with functions Creates a Vec2 structure with overloaded operators to create a new variable type for use as a 2D vector.
More...
#include <vec2.h>
Creates a Vec2 structure with functions Creates a Vec2 structure with overloaded operators to create a new variable type for use as a 2D vector.
Constructs an Vec2 Constructs the Vec2 setting the values to 0,0
Vec2::Vec2 |
( |
float |
inputX, |
|
|
float |
inputY |
|
) |
| |
|
inline |
Constructs a Vec2 Constructs the Vec2 setting the values to the input coordinates
- Parameters
-
float | The inputed x position |
float | The inputed y position |
Vec2* Vec2::operator*= |
( |
float |
a | ) |
|
|
inline |
Overloads the *= operator Overloads the *= operator allowing a Vec2 variable to use *=
- Parameters
-
float | the scalar to multiply by |
Overloads the += operator Overloads the += operator allowing a Vec2 variable to use +=
- Parameters
-
Overloads the -= operator Overloads the -= operator allowing a Vec2 variable to use -=
- Parameters
-
Vec2* Vec2::operator/= |
( |
float |
a | ) |
|
|
inline |
Overloads the /= operator Overloads the /= operator allowing a Vec2 variable to use /=
- Parameters
-
float | the scalar to divide by |
The documentation for this struct was generated from the following file:
- AIAssignment1LineOfSight/vec2.h