diff options
author | aap <aap@papnet.eu> | 2019-06-16 18:14:48 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-16 18:14:48 +0200 |
commit | bb526541a956f2876936b2e2320c5da9d32d94d1 (patch) | |
tree | 593f1f52b771e2acb82c923e016fcbf73b204a7a /src/Camera.cpp | |
parent | Merge branch 'master' of github.com:GTAmodding/re3 (diff) | |
parent | Changes for the pull request. (diff) | |
download | re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar.gz re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar.bz2 re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar.lz re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar.xz re3-bb526541a956f2876936b2e2320c5da9d32d94d1.tar.zst re3-bb526541a956f2876936b2e2320c5da9d32d94d1.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Camera.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/Camera.cpp b/src/Camera.cpp index 6054f1fc..ebe08f09 100644 --- a/src/Camera.cpp +++ b/src/Camera.cpp @@ -14,8 +14,7 @@ const float DefaultFOV = 80.0f; // actually 70.0f CCamera &TheCamera = *(CCamera*)0x6FACF8; - -WRAPPER Bool CCam::Using3rdPersonMouseCam() { EAXJMP(0x457460); } +Bool &CCamera::m_bUseMouse3rdPerson = *(Bool *)0x5F03D8; WRAPPER void CCamera::DrawBordersForWideScreen(void) { EAXJMP(0x46B430); } @@ -1250,6 +1249,14 @@ CCam::FixCamWhenObscuredByVehicle(const CVector &TargetCoors) Source.z += HeightFixerCarsObscuring; } +bool CCam::Using3rdPersonMouseCam() { + return CCamera::m_bUseMouse3rdPerson && + (Mode == MODE_FOLLOWPED || + TheCamera.m_bPlayerIsInGarage && + FindPlayerPed() && FindPlayerPed()->m_nPedState != PED_DRIVING && + Mode != MODE_TOPDOWN1 && this->CamTargetEntity == FindPlayerPed()); +} + STARTPATCHES InjectHook(0x42C760, &CCamera::IsSphereVisible, PATCH_JUMP); InjectHook(0x46FD00, &CCamera::SetFadeColour, PATCH_JUMP); |