From da0be4e4a42d8d87198435d48e54bd65a030922a Mon Sep 17 00:00:00 2001 From: yukani Date: Sat, 12 Oct 2024 23:32:14 +0300 Subject: [PATCH] suggests --- source/game_sa/Cam.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source/game_sa/Cam.cpp b/source/game_sa/Cam.cpp index ecaddaf93..f228f0e3b 100644 --- a/source/game_sa/Cam.cpp +++ b/source/game_sa/Cam.cpp @@ -430,17 +430,17 @@ void CCam::Process_Fixed(const CVector& target, float orientation, float speedVa GetVectorsReadyForRW(); // inlined? + const auto a = CrossProduct( + m_vecFront, + (m_vecCamFixedModeUpOffSet + CVector{ 0.0f, 0.0f, 1.0f }).Normalized() + ).Normalized(); m_vecUp = CrossProduct( - CrossProduct( - m_vecFront, - (m_vecCamFixedModeUpOffSet + CVector{ 0.0f, 0.0f, 1.0f }).Normalized() - ).Normalized(), + a, m_vecFront ); m_fFOV = 70.0f; - float waterLevel{}; - if (CWaterLevel::GetWaterLevel(m_vecSource, waterLevel, true) && m_vecSource.z < waterLevel) { + if (float wl{}; CWaterLevel::GetWaterLevel(m_vecSource, wl, true) && m_vecSource.z < wl) { ApplyUnderwaterMotionBlur(); }