Magic-number elimination.

This commit is contained in:
Eric S. Raymond 2017-07-02 14:47:21 -04:00
parent 369c67840e
commit e712f4c0e0
5 changed files with 12 additions and 10 deletions

View file

@ -45,9 +45,9 @@ long score(enum termination mode)
k = 14;
if (i > CHEST)
k = 16;
if (game.prop[i] >= 0)
if (game.prop[i] > STATE_NOTFOUND)
score += 2;
if (game.place[i] == LOC_BUILDING && game.prop[i] == 0)
if (game.place[i] == LOC_BUILDING && game.prop[i] == STATE_GROUND)
score += k - 2;
mxscor += k;
}