summaryrefslogtreecommitdiffstats
path: root/src/entities/Physical.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/entities/Physical.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/entities/Physical.cpp')
-rw-r--r--src/entities/Physical.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/entities/Physical.cpp b/src/entities/Physical.cpp
index af08ced6..a61aaa78 100644
--- a/src/entities/Physical.cpp
+++ b/src/entities/Physical.cpp
@@ -317,7 +317,7 @@ CPhysical::PlacePhysicalRelativeToOtherPhysical(CPhysical *other, CPhysical *phy
CWorld::Remove(phys);
phys->GetMatrix() = other->GetMatrix();
- phys->GetPosition() = pos;
+ phys->SetPosition(pos);
phys->m_vecMoveSpeed = other->m_vecMoveSpeed;
phys->GetMatrix().UpdateRW();
phys->UpdateRwFrame();
@@ -412,7 +412,7 @@ CPhysical::GetSpeed(const CVector &r)
void
CPhysical::ApplyMoveSpeed(void)
{
- GetPosition() += m_vecMoveSpeed * CTimer::GetTimeStep();
+ GetMatrix().Translate(m_vecMoveSpeed * CTimer::GetTimeStep());
}
void
@@ -1167,7 +1167,7 @@ CPhysical::ProcessShiftSectorList(CPtrList *lists)
float f = Min(Abs(dir.z), 0.9f);
dir.z = 0.0f;
dir.Normalise();
- B->GetPosition() += dir * colpoints[mostColliding].depth / (1.0f - f);
+ B->GetMatrix().Translate(dir * colpoints[mostColliding].depth / (1.0f - f));
// BUG? how can that ever happen? A is a Ped
if(B->IsVehicle())
B->ProcessEntityCollision(A, colpoints);
@@ -1184,7 +1184,7 @@ CPhysical::ProcessShiftSectorList(CPtrList *lists)
if(!doShift)
return false;
- GetPosition() += shift;
+ GetMatrix().Translate(shift);
if(boat)
ProcessEntityCollision(boat, colpoints);
return true;