diff --git a/advent.h b/advent.h index 1162106..c1d3132 100644 --- a/advent.h +++ b/advent.h @@ -167,7 +167,7 @@ struct game_t { int holdng; // number of objects being carried int igo; // # uses of "go" instead of a direction int iwest; // # times he's said "west" instead of "w" - int knfloc; // knife location; 0 if none, -1 after caveat + loc_t knfloc; // knife location; LOC_NOWERE if none, -1 after caveat turn_t limit; // lifetime of lamp loc_t loc; // where player is now loc_t newloc; // where player is going diff --git a/main.c b/main.c index cdc83ba..e3e6a96 100644 --- a/main.c +++ b/main.c @@ -370,7 +370,7 @@ static bool dwarfmove(void) ++game.dtotal; if (game.odloc[i] == game.dloc[i]) { ++attack; - if (game.knfloc >= 0) + if (game.knfloc >= LOC_NOWHERE) game.knfloc = game.loc; if (randrange(1000) < 95 * (game.dflag - 2)) ++stick;