one more original name

This commit is contained in:
aap 2020-12-03 19:11:57 +01:00
parent 0d166081ad
commit 43fb7fe342

View file

@ -942,26 +942,26 @@ CEntity *
CWorld::TestSphereAgainstSectorList(CPtrList &list, CVector spherePos, float radius, CEntity *entityToIgnore, CWorld::TestSphereAgainstSectorList(CPtrList &list, CVector spherePos, float radius, CEntity *entityToIgnore,
bool ignoreSomeObjects) bool ignoreSomeObjects)
{ {
static CColModel sphereCol; static CColModel OurColModel;
CColSphere sphere; CColSphere sphere;
sphereCol.boundingSphere.center.x = 0.0f; OurColModel.boundingSphere.center.x = 0.0f;
sphereCol.boundingSphere.center.y = 0.0f; OurColModel.boundingSphere.center.y = 0.0f;
sphereCol.boundingSphere.center.z = 0.0f; OurColModel.boundingSphere.center.z = 0.0f;
sphereCol.boundingSphere.radius = radius; OurColModel.boundingSphere.radius = radius;
sphereCol.boundingBox.min.x = -radius; OurColModel.boundingBox.min.x = -radius;
sphereCol.boundingBox.min.y = -radius; OurColModel.boundingBox.min.y = -radius;
sphereCol.boundingBox.min.z = -radius; OurColModel.boundingBox.min.z = -radius;
sphereCol.boundingBox.max.x = radius; OurColModel.boundingBox.max.x = radius;
sphereCol.boundingBox.max.y = radius; OurColModel.boundingBox.max.y = radius;
sphereCol.boundingBox.max.z = radius; OurColModel.boundingBox.max.z = radius;
sphereCol.numSpheres = 1; OurColModel.numSpheres = 1;
sphere.Set(radius, CVector(0.0f, 0.0f, 0.0f)); sphere.Set(radius, CVector(0.0f, 0.0f, 0.0f));
sphereCol.spheres = &sphere; OurColModel.spheres = &sphere;
sphereCol.numLines = 0; OurColModel.numLines = 0;
sphereCol.numBoxes = 0; OurColModel.numBoxes = 0;
sphereCol.numTriangles = 0; OurColModel.numTriangles = 0;
sphereCol.ownsCollisionVolumes = false; OurColModel.ownsCollisionVolumes = false;
CMatrix sphereMat; CMatrix sphereMat;
sphereMat.SetTranslate(spherePos); sphereMat.SetTranslate(spherePos);
@ -980,7 +980,7 @@ CWorld::TestSphereAgainstSectorList(CPtrList &list, CVector spherePos, float rad
if(e->GetBoundRadius() + radius > distance) { if(e->GetBoundRadius() + radius > distance) {
CColModel *eCol = CModelInfo::GetModelInfo(e->GetModelIndex())->GetColModel(); CColModel *eCol = CModelInfo::GetModelInfo(e->GetModelIndex())->GetColModel();
int collidedSpheres = int collidedSpheres =
CCollision::ProcessColModels(sphereMat, sphereCol, e->GetMatrix(), *eCol, CCollision::ProcessColModels(sphereMat, OurColModel, e->GetMatrix(), *eCol,
gaTempSphereColPoints, nil, nil); gaTempSphereColPoints, nil, nil);
if(collidedSpheres != 0 || if(collidedSpheres != 0 ||