summaryrefslogtreecommitdiff
path: root/src/hexen/am_map.c
diff options
context:
space:
mode:
authorSimon Howard2008-09-17 01:05:14 +0000
committerSimon Howard2008-09-17 01:05:14 +0000
commit55bb7e8935369cb392c705969ed626fe9c0c391c (patch)
tree8a7428c5504b089e19625d3657e75f9a8c0f2839 /src/hexen/am_map.c
parent61e77600041ba534d824943320e7ddddb8e4f6ce (diff)
downloadchocolate-doom-55bb7e8935369cb392c705969ed626fe9c0c391c.tar.gz
chocolate-doom-55bb7e8935369cb392c705969ed626fe9c0c391c.tar.bz2
chocolate-doom-55bb7e8935369cb392c705969ed626fe9c0c391c.zip
Convert MAXINT/MININT -> INT_MAX/INT_MIN in Heretic/Hexen code.
Subversion-branch: /branches/raven-branch Subversion-revision: 1234
Diffstat (limited to 'src/hexen/am_map.c')
-rw-r--r--src/hexen/am_map.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/hexen/am_map.c b/src/hexen/am_map.c
index be16a8ac..6678f325 100644
--- a/src/hexen/am_map.c
+++ b/src/hexen/am_map.c
@@ -126,9 +126,9 @@ void AM_getIslope(mline_t *ml, islope_t *is)
dy = ml->a.y - ml->b.y;
dx = ml->b.x - ml->a.x;
- if (!dy) is->islp = (dx<0?-MAXINT:MAXINT);
+ if (!dy) is->islp = (dx<0?-INT_MAX:INT_MAX);
else is->islp = FixedDiv(dx, dy);
- if (!dx) is->slp = (dy<0?-MAXINT:MAXINT);
+ if (!dx) is->slp = (dy<0?-INT_MAX:INT_MAX);
else is->slp = FixedDiv(dy, dx);
}
*/
@@ -192,8 +192,8 @@ void AM_findMinMaxBoundaries(void)
int i;
fixed_t a, b;
- min_x = min_y = MAXINT;
- max_x = max_y = -MAXINT;
+ min_x = min_y = INT_MAX;
+ max_x = max_y = -INT_MAX;
for (i = 0; i < numvertexes; i++)
{
if (vertexes[i].x < min_x)
@@ -223,7 +223,7 @@ void AM_changeWindowLoc(void)
if (m_paninc.x || m_paninc.y)
{
followplayer = 0;
- f_oldloc.x = MAXINT;
+ f_oldloc.x = INT_MAX;
}
m_x += m_paninc.x;
@@ -276,7 +276,7 @@ void AM_initVariables(void)
automapactive = true;
fb = screen;
- f_oldloc.x = MAXINT;
+ f_oldloc.x = INT_MAX;
amclock = 0;
lightlev = 0;
@@ -487,7 +487,7 @@ boolean AM_Responder(event_t * ev)
break;
case AM_FOLLOWKEY:
followplayer = !followplayer;
- f_oldloc.x = MAXINT;
+ f_oldloc.x = INT_MAX;
P_SetMessage(plr,
followplayer ? AMSTR_FOLLOWON : AMSTR_FOLLOWOFF,
true);
@@ -576,7 +576,7 @@ void AM_doFollowPlayer(void)
dmapx = (MTOF(plr->mo->x)-MTOF(f_oldloc.x)); //fixed point
dmapy = (MTOF(f_oldloc.y)-MTOF(plr->mo->y));
- if(f_oldloc.x == MAXINT) //to eliminate an error when the user first
+ if(f_oldloc.x == INT_MAX) //to eliminate an error when the user first
dmapx=0; //goes into the automap.
mapxstart += dmapx;
mapystart += dmapy;
@@ -650,7 +650,7 @@ void AM_clearFB(int color)
oldplr.x = plr->mo->x;
oldplr.y = plr->mo->y;
-// if(f_oldloc.x == MAXINT) //to eliminate an error when the user first
+// if(f_oldloc.x == INT_MAX) //to eliminate an error when the user first
// dmapx=0; //goes into the automap.
mapxstart += dmapx >> 1;
mapystart += dmapy >> 1;