summaryrefslogtreecommitdiffstats
path: root/src/peds/PlayerPed.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2021-07-26 06:41:34 +0200
committerSergeanur <s.anureev@yandex.ua>2021-07-26 06:41:34 +0200
commit1aac4d802f6cb12c35b877838c425c95fa92aea4 (patch)
treeaf69545816cc09376b802d2fea38d4cfecae91a0 /src/peds/PlayerPed.cpp
parentFix traffic light corona facing wrong side (diff)
downloadre3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar.gz
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar.bz2
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar.lz
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar.xz
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.tar.zst
re3-1aac4d802f6cb12c35b877838c425c95fa92aea4.zip
Diffstat (limited to 'src/peds/PlayerPed.cpp')
-rw-r--r--src/peds/PlayerPed.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/peds/PlayerPed.cpp b/src/peds/PlayerPed.cpp
index 8225189f..d96cb683 100644
--- a/src/peds/PlayerPed.cpp
+++ b/src/peds/PlayerPed.cpp
@@ -1221,11 +1221,21 @@ CPlayerPed::ProcessPlayerWeapon(CPad *padUsed)
}
if (padUsed->DuckJustDown() && !bIsDucking && m_nMoveState != PEDMOVE_SPRINT) {
+#ifdef FIX_BUGS
+ // fix tommy being locked into looking at the same spot if you duck just after starting to shoot
+ if(!m_pPointGunAt)
+ ClearPointGunAt();
+#endif
bCrouchWhenShooting = true;
SetDuck(60000, true);
} else if (bIsDucking && (padUsed->DuckJustDown() || m_nMoveState == PEDMOVE_SPRINT ||
padUsed->GetSprint() || padUsed->JumpJustDown() || padUsed->ExitVehicleJustDown())) {
+#ifdef FIX_BUGS
+ // same fix as above except for standing up
+ if(!m_pPointGunAt)
+ ClearPointGunAt();
+#endif
ClearDuck(true);
bCrouchWhenShooting = false;
}