aboutsummaryrefslogtreecommitdiff
path: root/primedev/core/math/vector.h
diff options
context:
space:
mode:
authorNorthstar <northstar@northstar.tf>2024-08-23 23:26:57 +0200
committerNorthstar <northstar@northstar.tf>2024-08-23 23:26:57 +0200
commit5b2c608b22ba272e4ab1a45adc1f43b60b1aea79 (patch)
treee827952268ac29f0c08f0891ddba09af1f089e5e /primedev/core/math/vector.h
parentd333a966ed961fca02d80212fe1384cf8600b9cb (diff)
downloadNorthstarLauncher-5b2c608b22ba272e4ab1a45adc1f43b60b1aea79.tar.gz
NorthstarLauncher-5b2c608b22ba272e4ab1a45adc1f43b60b1aea79.zip
Format project
Diffstat (limited to 'primedev/core/math/vector.h')
-rw-r--r--primedev/core/math/vector.h20
1 files changed, 4 insertions, 16 deletions
diff --git a/primedev/core/math/vector.h b/primedev/core/math/vector.h
index e62f2c93..0face732 100644
--- a/primedev/core/math/vector.h
+++ b/primedev/core/math/vector.h
@@ -17,10 +17,7 @@ public:
Vector3(float _f) : x(_f), y(_f), z(_f) {}
Vector3() : x(0.0f), y(0.0f), z(0.0f) {}
- inline bool IsValid()
- {
- return IsFinite(x) && IsFinite(y) && IsFinite(z);
- }
+ inline bool IsValid() { return IsFinite(x) && IsFinite(y) && IsFinite(z); }
inline void Init(float fX = 0.0f, float fY = 0.0f, float fZ = 0.0f)
{
@@ -29,10 +26,7 @@ public:
z = fZ;
}
- inline float Length()
- {
- return FastSqrt(x * x + y * y + z * z);
- }
+ inline float Length() { return FastSqrt(x * x + y * y + z * z); }
inline float DistTo(const Vector3& vOther)
{
@@ -44,10 +38,7 @@ public:
return vDelta.Length();
}
- float Dot(const Vector3& vOther) const
- {
- return x * vOther.x + y * vOther.y + z * vOther.z;
- }
+ float Dot(const Vector3& vOther) const { return x * vOther.x + y * vOther.y + z * vOther.z; }
// Cross product between two vectors.
Vector3 Cross(const Vector3& vOther) const;
@@ -318,10 +309,7 @@ public:
Vector3 GetNormal() const;
// todo: more operators maybe
- bool operator==(const QAngle& other)
- {
- return x == other.x && y == other.y && z == other.z;
- }
+ bool operator==(const QAngle& other) { return x == other.x && y == other.y && z == other.z; }
};
inline Vector3 QAngle::GetNormal() const