summaryrefslogtreecommitdiffstats
path: root/src/control/PathFind.cpp
diff options
context:
space:
mode:
authorFilip Gawin <filip.gawin@zoho.com>2019-08-02 17:43:40 +0200
committerFilip Gawin <filip.gawin@zoho.com>2019-08-27 21:14:28 +0200
commit458fc63f0196dc92362b44d5cf7ebf67bbc903e1 (patch)
treeaa190341ec4d5ee449c80c20fea3c09e4f655532 /src/control/PathFind.cpp
parentMore audio ped (diff)
downloadre3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar.gz
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar.bz2
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar.lz
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar.xz
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.tar.zst
re3-458fc63f0196dc92362b44d5cf7ebf67bbc903e1.zip
Diffstat (limited to 'src/control/PathFind.cpp')
-rw-r--r--src/control/PathFind.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/control/PathFind.cpp b/src/control/PathFind.cpp
index 87ce4476..e9b33395 100644
--- a/src/control/PathFind.cpp
+++ b/src/control/PathFind.cpp
@@ -207,8 +207,8 @@ CPathFind::PreparePathData(void)
numExtern++;
if(InfoForTileCars[k].numLeftLanes + InfoForTileCars[k].numRightLanes > numLanes)
numLanes = InfoForTileCars[k].numLeftLanes + InfoForTileCars[k].numRightLanes;
- maxX = Max(maxX, Abs(InfoForTileCars[k].x));
- maxY = Max(maxY, Abs(InfoForTileCars[k].y));
+ maxX = max(maxX, Abs(InfoForTileCars[k].x));
+ maxY = max(maxY, Abs(InfoForTileCars[k].y));
}else if(InfoForTileCars[k].type == NodeTypeIntern)
numIntern++;
}
@@ -392,7 +392,7 @@ CPathFind::PreparePathDataForType(uint8 type, CTempNode *tempnodes, CPathInfoFor
if(Abs(dx) < nearestDist){
dy = tempnodes[k].pos.y - CoorsXFormed.y;
if(Abs(dy) < nearestDist){
- nearestDist = Max(Abs(dx), Abs(dy));
+ nearestDist = max(Abs(dx), Abs(dy));
nearestId = k;
}
}
@@ -501,13 +501,13 @@ CPathFind::PreparePathDataForType(uint8 type, CTempNode *tempnodes, CPathInfoFor
// Find i inside path segment
iseg = 0;
- for(j = Max(oldNumPathNodes, i-12); j < i; j++)
+ for(j = max(oldNumPathNodes, i-12); j < i; j++)
if(m_pathNodes[j].objectIndex == m_pathNodes[i].objectIndex)
iseg++;
istart = 12*m_mapObjects[m_pathNodes[i].objectIndex]->m_modelIndex;
// Add links to other internal nodes
- for(j = Max(oldNumPathNodes, i-12); j < Min(m_numPathNodes, i+12); j++){
+ for(j = max(oldNumPathNodes, i-12); j < min(m_numPathNodes, i+12); j++){
if(m_pathNodes[i].objectIndex != m_pathNodes[j].objectIndex || i == j)
continue;
// N.B.: in every path segment, the externals have to be at the end