aboutsummaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2021-05-27 16:50:15 +0300
committerSergeanur <s.anureev@yandex.ua>2021-06-24 21:32:43 +0300
commit2ad3a75be5ba34d1376ad7c3fa7fc94adeaa32ac (patch)
tree15efc250158c790c0b73e44a7692dc21b0d9cc9c /src/core
parent50058371efaf4c5713b7a608db0c7990ec3d78a6 (diff)
Fix IsSphereVisible calls
Diffstat (limited to 'src/core')
-rw-r--r--src/core/Camera.cpp4
-rw-r--r--src/core/Camera.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/core/Camera.cpp b/src/core/Camera.cpp
index 5c86ca99..5881dacd 100644
--- a/src/core/Camera.cpp
+++ b/src/core/Camera.cpp
@@ -3650,7 +3650,7 @@ CCamera::IsPointVisible(const CVector &center, const CMatrix *mat)
}
bool
-CCamera::IsSphereVisible(const CVector &center, float radius, const CMatrix *mat)
+CCamera::IsSphereVisible(const CVector &center, float radius, Const CMatrix *mat)
{
#ifdef GTA_PS2
CVuVector c;
@@ -3680,7 +3680,7 @@ CCamera::IsSphereVisible(const CVector &center, float radius)
return IsSphereVisible(center, radius, &m_cameraMatrix);
#else
// ...and on PC they decided to call the other one with a default matrix.
- CMatrix mat(m_cameraMatrix); // this matrix construction is stupid and gone in VC
+ CMatrix mat(GetCameraMatrix()); // this matrix construction is stupid and gone in VC
return IsSphereVisible(center, radius, &mat);
#endif
}
diff --git a/src/core/Camera.h b/src/core/Camera.h
index 5e9d33b3..07a05cb4 100644
--- a/src/core/Camera.h
+++ b/src/core/Camera.h
@@ -639,7 +639,7 @@ public:
CVector &GetGameCamPosition(void) { return m_vecGameCamPos; }
void CalculateDerivedValues(void);
bool IsPointVisible(const CVector &center, const CMatrix *mat);
- bool IsSphereVisible(const CVector &center, float radius, const CMatrix *mat);
+ bool IsSphereVisible(const CVector &center, float radius, Const CMatrix *mat);
bool IsSphereVisible(const CVector &center, float radius);
bool IsBoxVisible(CVUVECTOR *box, const CMatrix *mat);
};