summaryrefslogtreecommitdiffstats
path: root/src/core/Camera.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2021-05-23 17:45:07 +0200
committerSergeanur <s.anureev@yandex.ua>2021-06-24 20:32:43 +0200
commit50058371efaf4c5713b7a608db0c7990ec3d78a6 (patch)
tree314722ae778432755c8ea0563a317df52fe130ee /src/core/Camera.cpp
parentUndef PS2_AUDIO_CHANNELS for SQUEEZE_PERFORMANCE and VANILLA_DEFINES (diff)
downloadre3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar.gz
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar.bz2
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar.lz
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar.xz
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.tar.zst
re3-50058371efaf4c5713b7a608db0c7990ec3d78a6.zip
Diffstat (limited to '')
-rw-r--r--src/core/Camera.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/core/Camera.cpp b/src/core/Camera.cpp
index fd2d5eed..5c86ca99 100644
--- a/src/core/Camera.cpp
+++ b/src/core/Camera.cpp
@@ -3675,16 +3675,18 @@ CCamera::IsSphereVisible(const CVector &center, float radius, const CMatrix *mat
bool
CCamera::IsSphereVisible(const CVector &center, float radius)
{
- CMatrix mat = m_cameraMatrix;
+#if GTA_VERSION < GTA3_PC_10 // not sure this condition is the right one
+ // Maybe this was a copy of the other function with m_cameraMatrix
+ 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
return IsSphereVisible(center, radius, &mat);
+#endif
}
bool
-#ifdef GTA_PS2
-CCamera::IsBoxVisible(CVuVector *box, const CMatrix *mat)
-#else
-CCamera::IsBoxVisible(CVector *box, const CMatrix *mat)
-#endif
+CCamera::IsBoxVisible(CVUVECTOR *box, const CMatrix *mat)
{
int i;
int frustumTests[6] = { 0 };