diff options
author | aap <aap@papnet.eu> | 2020-11-16 22:43:35 +0100 |
---|---|---|
committer | aap <aap@papnet.eu> | 2020-11-16 22:43:35 +0100 |
commit | 46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44 (patch) | |
tree | 0ba07eade718824f6384d9baabf733f9752410ef /src/control | |
parent | animation compression from PS2 (diff) | |
parent | pragma twice (diff) | |
download | re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar.gz re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar.bz2 re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar.lz re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar.xz re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.tar.zst re3-46253fbf7d2a1b0cf9d2f0ab5f7e79035a997b44.zip |
Diffstat (limited to 'src/control')
-rw-r--r-- | src/control/CarCtrl.cpp | 2 | ||||
-rw-r--r-- | src/control/PathFind.cpp | 16 |
2 files changed, 17 insertions, 1 deletions
diff --git a/src/control/CarCtrl.cpp b/src/control/CarCtrl.cpp index 76ee47b0..627d7bad 100644 --- a/src/control/CarCtrl.cpp +++ b/src/control/CarCtrl.cpp @@ -2692,7 +2692,7 @@ void CCarCtrl::GenerateEmergencyServicesCar(void) float distance = 30.0f; CFire* pNearestFire = gFireManager.FindNearestFire(FindPlayerCoors(), &distance); if (pNearestFire) { - if (CountCarsOfType(MI_FIRETRUCK) < 2 && CTimer::GetTimeInMilliseconds() > LastTimeFireTruckCreated + 30000){ + if (CountCarsOfType(MI_FIRETRUCK) < 2 && CTimer::GetTimeInMilliseconds() > LastTimeFireTruckCreated + 35000){ CStreaming::RequestModel(MI_FIRETRUCK, STREAMFLAGS_DEPENDENCY); CStreaming::RequestModel(MI_FIREMAN, STREAMFLAGS_DONT_REMOVE); if (CStreaming::HasModelLoaded(MI_FIRETRUCK) && CStreaming::HasModelLoaded(MI_FIREMAN)){ diff --git a/src/control/PathFind.cpp b/src/control/PathFind.cpp index fb60250c..ecd2d0cb 100644 --- a/src/control/PathFind.cpp +++ b/src/control/PathFind.cpp @@ -542,6 +542,22 @@ CPathFind::PreparePathDataForType(uint8 type, CTempNode *tempnodes, CPathInfoFor int done, cont; int tileStart; +#ifndef MASTER + for (i = 0; i < m_numMapObjects-1; i++) + for (j = i+1; j < m_numMapObjects; j++) { + CTreadable *obj1 = m_mapObjects[i]; + CTreadable *obj2 = m_mapObjects[j]; + if (obj1->GetModelIndex() == obj2->GetModelIndex() && + obj1->GetPosition().x == obj2->GetPosition().x && obj1->GetPosition().y == obj2->GetPosition().y && obj1->GetPosition().z == obj2->GetPosition().z && + obj1->GetRight().x == obj2->GetRight().x && obj1->GetForward().x == obj2->GetForward().x && obj1->GetUp().x == obj2->GetUp().x && + obj1->GetRight().y == obj2->GetRight().y && obj1->GetForward().y == obj2->GetForward().y && obj1->GetUp().y == obj2->GetUp().y && + obj1->GetRight().z == obj2->GetRight().z && obj1->GetForward().z == obj2->GetForward().z && obj1->GetUp().z == obj2->GetUp().z) { + printf("THIS IS VERY BAD INDEED. FIX IMMEDIATELY!!!\n"); + printf("Double road objects at the following coors: %f %f %f\n", obj1->GetPosition().x, obj1->GetPosition().y, obj1->GetPosition().z); + } + } +#endif // !MASTER + oldNumPathNodes = m_numPathNodes; oldNumLinks = m_numConnections; |