Magic-number elimination.

This commit is contained in:
Eric S. Raymond 2017-06-16 07:00:57 -04:00
parent 1b5ab6c808
commit a57d93ce35
6 changed files with 28 additions and 24 deletions

View file

@ -41,7 +41,7 @@ void score(enum termination mode)
if(i > CHEST)k=16;
if(game.prop[i] >= 0)
score += 2;
if(game.place[i] == 3 && game.prop[i] == 0)
if(game.place[i] == LOC_BUILDING && game.prop[i] == 0)
score += k-2;
mxscor += k;
}
@ -75,7 +75,7 @@ void score(enum termination mode)
mxscor += 45;
/* Did he come to Witt's End as he should? */
if(game.place[MAGZIN] == 108)
if(game.place[MAGZIN] == LOC_WITTSEND)
score += 1;
mxscor += 1;