Mercurial > hg > early-roguelike
changeset 39:d7d45e980791
srogue: fix bug causing healing on invalid commands.
author | elwin |
---|---|
date | Sat, 27 Nov 2010 16:49:44 +0000 |
parents | 8a9525231fb6 |
children | 984f7d5afb6f |
files | srogue/daemons.c srogue/main.c |
diffstat | 2 files changed, 8 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/srogue/daemons.c Sat Nov 27 16:22:30 2010 +0000 +++ b/srogue/daemons.c Sat Nov 27 16:49:44 2010 +0000 @@ -66,7 +66,7 @@ swander(fromfuse) int fromfuse; { - daemon(rollwand, TRUE, BEFORE); + daemon(rollwand, TRUE, AFTER); }
--- a/srogue/main.c Sat Nov 27 16:22:30 2010 +0000 +++ b/srogue/main.c Sat Nov 27 16:49:44 2010 +0000 @@ -242,9 +242,14 @@ /* Start up daemons and fuses */ daemon(status, TRUE, BEFORE); - daemon(doctor, TRUE, BEFORE); - daemon(stomach, TRUE, BEFORE); daemon(runners, TRUE, AFTER); + /* + * These daemons have been moved to AFTER because BEFORE daemons + * get called every command, even invalid ones. Hopefully this + * won't break anything. + */ + daemon(doctor, TRUE, AFTER); + daemon(stomach, TRUE, AFTER); fuse(swander, TRUE, WANDERTIME); /* Give the rogue his weaponry */