Fix a bunch of CModelInfo::GetModelInfo->GetColModel calls

This commit is contained in:
Sergeanur
2021-08-11 08:35:01 +03:00
parent 0544beb00d
commit d7a28c4d2b
9 changed files with 21 additions and 21 deletions

View File

@@ -202,7 +202,7 @@ bool CCarGenerator::CheckForBlockage(int32 mi)
{
int16 entities;
CEntity* pEntities[8];
CColModel* pColModel = CModelInfo::GetModelInfo(mi)->GetColModel();
CColModel* pColModel = CModelInfo::GetColModel(mi);
CWorld::FindObjectsKindaColliding(CVector(m_vecPos), pColModel->boundingSphere.radius, 1, &entities, 8, pEntities, false, true, true, false, false);
for (int i = 0; i < entities; i++) {
if (m_vecPos.z + pColModel->boundingBox.min.z < pEntities[i]->GetPosition().z + pEntities[i]->GetColModel()->boundingBox.max.z + 1.0f &&