|
Mineserver
A rewrite of Minecraft 1.8.9 in C++ !
|
Vector 3 (x, y, z) with variable type. More...
#include <vector.hpp>
Public Member Functions | |
| Vec () | |
| Construct a new Vec object. | |
| Vec (T x, T y) | |
| Construct a new Vec object. | |
| Vec (T x, T y, T z) | |
| Construct a new Vec object. | |
| ~Vec ()=default | |
| Destroy the Vec object. | |
| template<typename O > | |
| Vec (const Vec< O > &other) | |
| Construct a new Vec object from another. | |
| template<typename O > | |
| Vec & | operator+ (const Vec< O > &other) |
| Vector Addition operator. | |
| template<typename O > | |
| Vec & | operator- (const Vec< O > &other) |
| Vector Substraction operator. | |
| template<typename O > | |
| Vec & | operator* (const Vec< O > &other) |
| Vector Multiplication operator. | |
| template<typename O > | |
| Vec & | operator/ (const Vec< O > &other) |
| Vector Division operator. | |
| template<typename O > | |
| Vec & | operator* (const O &other) |
| Scalar Multiplication operator. | |
| template<typename O > | |
| Vec & | operator/ (const O &other) |
| Scalar Division operator. | |
Public Attributes | |
| T | x |
| X coordinate. | |
| T | y |
| Y coordinate. | |
| T | z |
| Z coordinate. | |
Vector 3 (x, y, z) with variable type.
| T | the type to use for x, y, z coordinates |
Construct a new Vec object.
All coordinates are set as 0.
Construct a new Vec object.
The z coordinate is set to 0.
| x | the x coordinate |
| y | the y coordinate |
Construct a new Vec object.
| x | the x coordinate |
| y | the y coordinate |
| z | the z coordinate |
Construct a new Vec object from another.
| O | the type of the other vector |
| other | the other vector |
Scalar Multiplication operator.
| O | the type of the scalar (should be arithmetic type) |
| other | the other scalar |
Vector Multiplication operator.
| O | the type of the other vector |
| other | the other vector |
Vector Addition operator.
| O | the type of the other vector |
| other | the other vector |
Vector Substraction operator.
| O | the type of the other vector |
| other | the other vector |
Scalar Division operator.
| O | the type of the scalar (should be arithmetic type) |
| other | the other scalar |
Vector Division operator.
| O | the type of the other vector |
| other | the other vector |