Magic-number elimination.
This commit is contained in:
parent
369c67840e
commit
e712f4c0e0
5 changed files with 12 additions and 10 deletions
4
score.c
4
score.c
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue