diff options
| author | lepelog <lepelog@users.noreply.github.com> | 2021-04-08 00:29:42 +0200 |
|---|---|---|
| committer | lepelog <lepelog@users.noreply.github.com> | 2021-04-08 00:29:42 +0200 |
| commit | 80051063ffbb9152cbd0b55917983f7d4b183aa4 (patch) | |
| tree | 6165de11573a1b902118b70e86a673fade7c750f /include/SSystem/SComponent | |
| parent | ed3df566445bc3dff0414b6620d1eb84578fd4c9 (diff) | |
c_xyz and c_angle sinit
Diffstat (limited to 'include/SSystem/SComponent')
| -rw-r--r-- | include/SSystem/SComponent/c_angle.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/include/SSystem/SComponent/c_angle.h b/include/SSystem/SComponent/c_angle.h index 9ee8338bee..4b569623cb 100644 --- a/include/SSystem/SComponent/c_angle.h +++ b/include/SSystem/SComponent/c_angle.h @@ -9,7 +9,13 @@ private: s16 mAngle; public: + const static cSAngle _0; + const static cSAngle _1; + const static cSAngle _90; + const static cSAngle _180; + const static cSAngle _270; cSAngle() {} + ~cSAngle() {} cSAngle(const cSAngle&); cSAngle(s16); cSAngle(float); @@ -39,8 +45,8 @@ public: bool operator>(const cSAngle& other) const { return mAngle > other.mAngle; } operator s16(void) const { return mAngle; } void operator=(const cSAngle& other) { mAngle = other.mAngle; } - static cSAngle getMaxNegative(void) { return cSAngle((s16)-0x8000); } - void mirrorAtMaxNeg(void) { *this = getMaxNegative() - *this; } + static inline cSAngle getMaxNegative(void) { return cSAngle((s16)-0x8000); } + inline void mirrorAtMaxNeg(void) { *this = cSAngle((s16)-0x8000) - *this; } }; cSAngle operator+(short, const cSAngle&); |
