diff options
Diffstat (limited to 'src/core/Camera.cpp')
-rw-r--r-- | src/core/Camera.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core/Camera.cpp b/src/core/Camera.cpp index 775ab46a..28cced53 100644 --- a/src/core/Camera.cpp +++ b/src/core/Camera.cpp @@ -1349,6 +1349,14 @@ CCamera::TakeControlWithSpline(short nSwitch) //FindPlayerPed(); // unused }; +void CCamera::SetCameraDirectlyInFrontForFollowPed_CamOnAString()
+{
+ m_bCamDirectlyInFront = true;
+ CPlayerPed *player = FindPlayerPed();
+ if (player)
+ m_PedOrientForBehindOrInFront = CGeneral::GetATanOfXY(player->GetForward().x, player->GetForward().y);
+} + STARTPATCHES InjectHook(0x42C760, (bool (CCamera::*)(const CVector ¢er, float radius, const CMatrix *mat))&CCamera::IsSphereVisible, PATCH_JUMP); InjectHook(0x46FD00, &CCamera::SetFadeColour, PATCH_JUMP); @@ -1357,6 +1365,8 @@ STARTPATCHES InjectHook(0x46FD80, &CCamera::SetMotionBlurAlpha, PATCH_JUMP); InjectHook(0x46F940, &CCamera::RenderMotionBlur, PATCH_JUMP); + InjectHook(0x46FC90, &CCamera::SetCameraDirectlyInFrontForFollowPed_CamOnAString, PATCH_JUMP); + InjectHook(0x456F40, WellBufferMe, PATCH_JUMP); InjectHook(0x4582F0, &CCam::GetVectorsReadyForRW, PATCH_JUMP); InjectHook(0x457710, &CCam::DoAverageOnVector, PATCH_JUMP); |