|
@@ -16,7 +16,6 @@ class Vector2
|
|
|
Vector2 operator * (const Vector2& rhs) const;
|
|
Vector2 operator * (const Vector2& rhs) const;
|
|
|
Vector2 operator / (float rhs) const;
|
|
Vector2 operator / (float rhs) const;
|
|
|
Vector2 operator / (const Vector2& rhs) const;
|
|
Vector2 operator / (const Vector2& rhs) const;
|
|
|
- Vector2 operator / (const Vector2& rhs) const;
|
|
|
|
|
|
|
|
|
|
void Normalize();
|
|
void Normalize();
|
|
|
float Length() const;
|
|
float Length() const;
|
|
@@ -29,7 +28,6 @@ class Vector2
|
|
|
Vector2 Lerp(const Vector2& rhs, float t) const;
|
|
Vector2 Lerp(const Vector2& rhs, float t) const;
|
|
|
bool Equals(const Vector2& rhs) const;
|
|
bool Equals(const Vector2& rhs) const;
|
|
|
bool IsNaN() const;
|
|
bool IsNaN() const;
|
|
|
-
|
|
|
|
|
Vector2 Normalized() const;
|
|
Vector2 Normalized() const;
|
|
|
|
|
|
|
|
String ToString() const;
|
|
String ToString() const;
|
|
@@ -57,7 +55,9 @@ class IntVector2
|
|
|
IntVector2 operator - () const;
|
|
IntVector2 operator - () const;
|
|
|
IntVector2 operator - (const IntVector2& rhs) const;
|
|
IntVector2 operator - (const IntVector2& rhs) const;
|
|
|
IntVector2 operator * (int rhs) const;
|
|
IntVector2 operator * (int rhs) const;
|
|
|
|
|
+ IntVector2 operator * (const IntVector2& rhs) const;
|
|
|
IntVector2 operator / (int rhs) const;
|
|
IntVector2 operator / (int rhs) const;
|
|
|
|
|
+ IntVector2 operator / (const IntVector2& rhs) const;
|
|
|
|
|
|
|
|
String ToString() const;
|
|
String ToString() const;
|
|
|
unsigned ToHash() const;
|
|
unsigned ToHash() const;
|
|
@@ -67,6 +67,11 @@ class IntVector2
|
|
|
int y_ @ y;
|
|
int y_ @ y;
|
|
|
|
|
|
|
|
static const IntVector2 ZERO;
|
|
static const IntVector2 ZERO;
|
|
|
|
|
+ static const IntVector2 LEFT;
|
|
|
|
|
+ static const IntVector2 RIGHT;
|
|
|
|
|
+ static const IntVector2 UP;
|
|
|
|
|
+ static const IntVector2 DOWN;
|
|
|
|
|
+ static const IntVector2 ONE;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
Vector2 VectorLerp(const Vector2& lhs, const Vector2& rhs, const Vector2& t);
|
|
Vector2 VectorLerp(const Vector2& lhs, const Vector2& rhs, const Vector2& t);
|