From 1d0bbfd0b820b276b48bfac271ad5f189afb9ea6 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Sun, 26 Feb 2006 15:55:43 +0000 Subject: [PATCH] =?UTF-8?q?http://eressea.upb.de/mantis/view.php=3Fid=3D86?= =?UTF-8?q?0=20-=20Frische=20Untote=20f=C3=BChren=20lange=20Befehle=20aus.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/gamecode/monster.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/common/gamecode/monster.c b/src/common/gamecode/monster.c index eb1866e82..1bb4eef1d 100644 --- a/src/common/gamecode/monster.c +++ b/src/common/gamecode/monster.c @@ -353,6 +353,7 @@ monster_move(region * r, unit * u) { direction_t d = NODIRECTION; + if (is_waiting(u)) return NULL; switch(old_race(u->race)) { case RC_FIREDRAGON: case RC_DRAGON: @@ -452,13 +453,14 @@ static order * make_movement_order(unit * u, const region * target, int moves, boolean (*allowed)(const region *, const region *)) { region * r = u->region; - region ** plan = path_find(r, target, DRAGON_RANGE*5, allowed); + region ** plan; int position = 0; char * c; - if (plan==NULL) { - return NULL; - } + if (is_waiting(u)) return NULL; + + plan = path_find(r, target, DRAGON_RANGE*5, allowed); + if (plan==NULL) return NULL; strcpy(buf, locale_string(u->faction->locale, keywords[K_MOVE])); c = buf + strlen(buf);