summaryrefslogtreecommitdiffstats
path: root/src/vehicles/Plane.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-05-05 03:45:18 +0200
committerSergeanur <s.anureev@yandex.ua>2020-05-05 03:45:18 +0200
commit84c9484e55874c57c1c017cb2394e0c6b2f32303 (patch)
treebcd2cbc38055ee38aa1aa2b35dd46d0f5e2e0772 /src/vehicles/Plane.cpp
parentMerge pull request #508 from Nick007J/master (diff)
downloadre3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar.gz
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar.bz2
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar.lz
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar.xz
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.tar.zst
re3-84c9484e55874c57c1c017cb2394e0c6b2f32303.zip
Diffstat (limited to 'src/vehicles/Plane.cpp')
-rw-r--r--src/vehicles/Plane.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/vehicles/Plane.cpp b/src/vehicles/Plane.cpp
index 10ce225a..71189d84 100644
--- a/src/vehicles/Plane.cpp
+++ b/src/vehicles/Plane.cpp
@@ -359,8 +359,8 @@ CPlane::ProcessControl(void)
CVector posFront2 = (1.0f - f)*pPathNodes[curPathNodeFront2].p + f*pPathNodes[nextPathNodeFront2].p;
// Now set matrix
- GetPosition() = (posRear + posFront)/2.0f;
- GetPosition().z += 4.3f;
+ GetMatrix().GetPosition() = (posRear + posFront) / 2.0f;
+ GetMatrix().GetPosition().z += 4.3f;
CVector fwd = posFront - posRear;
fwd.Normalise();
if(pitch != 0.0f){
@@ -375,9 +375,9 @@ CPlane::ProcessControl(void)
right.z += 3.0f*roll.z;
right.Normalise();
CVector up = CrossProduct(right, fwd);
- GetRight() = right;
- GetUp() = up;
- GetForward() = fwd;
+ GetMatrix().GetRight() = right;
+ GetMatrix().GetUp() = up;
+ GetMatrix().GetForward() = fwd;
// Set speed
m_vecMoveSpeed = fwd*PlanePathSpeed[m_nPlaneId]/60.0f;
@@ -511,8 +511,8 @@ CPlane::ProcessControl(void)
CVector posFront2 = (1.0f - f)*pathNodes[curPathNodeFront2].p + f*pathNodes[nextPathNodeFront2].p;
// Now set matrix
- GetPosition() = (posRear + posFront)/2.0f;
- GetPosition().z += 1.0f;
+ GetMatrix().GetPosition() = (posRear + posFront) / 2.0f;
+ GetMatrix().GetPosition().z += 1.0f;
CVector fwd = posFront - posRear;
fwd.Normalise();
CVector fwd2 = posFront2 - posRear;
@@ -522,9 +522,9 @@ CPlane::ProcessControl(void)
right.z += 3.0f*roll.z;
right.Normalise();
CVector up = CrossProduct(right, fwd);
- GetRight() = right;
- GetUp() = up;
- GetForward() = fwd;
+ GetMatrix().GetRight() = right;
+ GetMatrix().GetUp() = up;
+ GetMatrix().GetForward() = fwd;
// Set speed
m_vecMoveSpeed = fwd*planePathSpeed/60.0f;