diff options
author | Nikolay Korolev <nickvnuk@gmail.com> | 2020-05-06 18:04:52 +0200 |
---|---|---|
committer | Nikolay Korolev <nickvnuk@gmail.com> | 2020-05-06 18:04:52 +0200 |
commit | d5e76471ae48bd3a31edb987d1c5366e7a67b3e2 (patch) | |
tree | 07a8ff3df033c62c58b6d27dfb94227e92b384c9 /src/core/World.cpp | |
parent | Merge remote-tracking branch 'upstream/miami' into miami (diff) | |
parent | CSphere and CBox for CColModel (diff) | |
download | re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar.gz re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar.bz2 re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar.lz re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar.xz re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.tar.zst re3-d5e76471ae48bd3a31edb987d1c5366e7a67b3e2.zip |
Diffstat (limited to 'src/core/World.cpp')
-rw-r--r-- | src/core/World.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/core/World.cpp b/src/core/World.cpp index c884f1ed..29505481 100644 --- a/src/core/World.cpp +++ b/src/core/World.cpp @@ -920,6 +920,7 @@ CWorld::TestSphereAgainstSectorList(CPtrList &list, CVector spherePos, float rad bool ignoreSomeObjects) { static CColModel sphereCol; + CColSphere sphere; sphereCol.boundingSphere.center.x = 0.0f; sphereCol.boundingSphere.center.y = 0.0f; @@ -932,7 +933,8 @@ CWorld::TestSphereAgainstSectorList(CPtrList &list, CVector spherePos, float rad sphereCol.boundingBox.max.y = radius; sphereCol.boundingBox.max.z = radius; sphereCol.numSpheres = 1; - sphereCol.spheres = &sphereCol.boundingSphere; + sphere.Set(radius, CVector(0.0f, 0.0f, 0.0f)); + sphereCol.spheres = &sphere; sphereCol.numLines = 0; sphereCol.numBoxes = 0; sphereCol.numTriangles = 0; @@ -1201,7 +1203,7 @@ CWorld::FindObjectsIntersectingCubeSectorList(CPtrList &list, const CVector &vec } void -CWorld::FindObjectsIntersectingAngledCollisionBox(const CColBox &boundingBox, const CMatrix &matrix, +CWorld::FindObjectsIntersectingAngledCollisionBox(const CBox &boundingBox, const CMatrix &matrix, const CVector &position, float fStartX, float fStartY, float fEndX, float fEndY, int16 *nEntitiesFound, int16 maxEntitiesToFind, CEntity **aEntities, bool bBuildings, bool bVehicles, bool bPeds, @@ -1261,7 +1263,7 @@ CWorld::FindObjectsIntersectingAngledCollisionBox(const CColBox &boundingBox, co } void -CWorld::FindObjectsIntersectingAngledCollisionBoxSectorList(CPtrList &list, const CColBox &boundingBox, +CWorld::FindObjectsIntersectingAngledCollisionBoxSectorList(CPtrList &list, const CBox &boundingBox, const CMatrix &matrix, const CVector &position, int16 *nEntitiesFound, int16 maxEntitiesToFind, CEntity **aEntities) |