summaryrefslogtreecommitdiffstats
path: root/src/control
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2020-04-25 11:15:29 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2020-04-25 11:15:29 +0200
commit34ef766c67b50b6abf4a05a77521e2393b116cca (patch)
tree3005e50fdcd82c3a9dc604fdcd89e694d5f621b8 /src/control
parentundo (diff)
parentdisable mouse steering by default (diff)
downloadre3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar.gz
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar.bz2
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar.lz
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar.xz
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.tar.zst
re3-34ef766c67b50b6abf4a05a77521e2393b116cca.zip
Diffstat (limited to 'src/control')
-rw-r--r--src/control/Script.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/control/Script.cpp b/src/control/Script.cpp
index a4ad15a9..1f65ce6e 100644
--- a/src/control/Script.cpp
+++ b/src/control/Script.cpp
@@ -6415,9 +6415,7 @@ int8 CRunningScript::ProcessCommands800To899(int32 command)
pPed->FlagToDestroyWhenNextProcessed();
}
else if (CGame::nastyGame && pPed->IsPedInControl()) {
- RwMatrix tmp_rw;
- CPedIK::GetWorldMatrix(pPed->m_pFrames[PED_HEAD]->frame, &tmp_rw);
- pPed->ApplyHeadShot(WEAPONTYPE_SNIPERRIFLE, tmp_rw.pos, true);
+ pPed->ApplyHeadShot(WEAPONTYPE_SNIPERRIFLE, pPed->GetNodePosition(PED_HEAD), true);
}
else {
pPed->SetDie(ANIM_KO_SHOT_FRONT1, 4.0f, 0.0f);
@@ -6430,9 +6428,7 @@ int8 CRunningScript::ProcessCommands800To899(int32 command)
CPed* pPed = CWorld::Players[ScriptParams[0]].m_pPed;
assert(pPed);
if (CGame::nastyGame) {
- RwMatrix tmp_rw;
- CPedIK::GetWorldMatrix(pPed->m_pFrames[PED_HEAD]->frame, &tmp_rw);
- pPed->ApplyHeadShot(WEAPONTYPE_SNIPERRIFLE, tmp_rw.pos, true);
+ pPed->ApplyHeadShot(WEAPONTYPE_SNIPERRIFLE, pPed->GetNodePosition(PED_HEAD), true);
}
else {
pPed->SetDie(ANIM_KO_SHOT_FRONT1, 4.0f, 0.0f);