implemented CHeli

This commit is contained in:
aap 2019-08-04 00:31:00 +02:00
parent 3b9b0646b8
commit a3e3527a3b
15 changed files with 1187 additions and 52 deletions

View file

@ -20,6 +20,29 @@ public:
}else
x = 0.0f;
}
const CVector2D &operator+=(CVector2D const &right) {
x += right.x;
y += right.y;
return *this;
}
const CVector2D &operator-=(CVector2D const &right) {
x -= right.x;
y -= right.y;
return *this;
}
const CVector2D &operator*=(float right) {
x *= right;
y *= right;
return *this;
}
const CVector2D &operator/=(float right) {
x /= right;
y /= right;
return *this;
}
CVector2D operator-(const CVector2D &rhs) const {
return CVector2D(x-rhs.x, y-rhs.y);
}