summaryrefslogtreecommitdiffstats
path: root/src/entities/Physical.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/entities/Physical.h')
-rw-r--r--src/entities/Physical.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/entities/Physical.h b/src/entities/Physical.h
index c84686ed..b6e28275 100644
--- a/src/entities/Physical.h
+++ b/src/entities/Physical.h
@@ -46,7 +46,7 @@ public:
float m_fDistanceTravelled;
// damaged piece
- float m_fDamageImpulse;
+ float m_fDamageImpulse; // fCollisionPower
CEntity *m_pDamageEntity;
CVector m_vecDamageNormal;
int16 m_nDamagePieceType;
@@ -117,6 +117,17 @@ public:
void SetMoveSpeed(const CVector& speed) {
m_vecMoveSpeed = speed;
}
+ void AddToMoveSpeed(float x, float y, float z) {
+ m_vecMoveSpeed.x += x;
+ m_vecMoveSpeed.y += y;
+ m_vecMoveSpeed.z += z;
+ }
+ void AddToMoveSpeed(const CVector& addition) {
+ m_vecMoveSpeed += addition;
+ }
+ void AddToMoveSpeed(const CVector2D& addition) {
+ m_vecMoveSpeed += CVector(addition.x, addition.y, 0.0f);
+ }
const CVector &GetTurnSpeed() { return m_vecTurnSpeed; }
void SetTurnSpeed(float x, float y, float z) {
m_vecTurnSpeed.x = x;
@@ -160,5 +171,3 @@ public:
bool CheckCollision(void);
bool CheckCollision_SimpleCar(void);
};
-
-VALIDATE_SIZE(CPhysical, 0x128);