From cd5f05d223b9440d135539f374aa81eb4ba4801b Mon Sep 17 00:00:00 2001 From: Playtester Date: Thu, 10 May 2007 17:52:46 +0000 Subject: Attempt to fix unwanted teleporting of immobile mobs git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10525 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/mob.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/map/mob.c') diff --git a/src/map/mob.c b/src/map/mob.c index 8942c4c1a..4e97c1bef 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -1045,7 +1045,10 @@ int mob_randomwalk(struct mob_data *md,int tick) nullpo_retr(0, md); - if(DIFF_TICK(md->next_walktime,tick)>0 || md->state.no_random_walk || !unit_can_move(&md->bl)) + if(DIFF_TICK(md->next_walktime,tick)>0 || + md->state.no_random_walk || + !unit_can_move(&md->bl) || + !(status_get_mode(&md->bl)&MD_CANMOVE)) return 0; d =12-md->move_fail_count; -- cgit v1.2.3-60-g2f50