diff options
author | Matheus Macabu <mkbu95@gmail.com> | 2013-04-22 22:23:14 -0300 |
---|---|---|
committer | Matheus Macabu <mkbu95@gmail.com> | 2013-04-22 22:23:14 -0300 |
commit | 038174e232c03519474f86e5738cecac34bbdee3 (patch) | |
tree | d253f065a140d0707064d8b413e760559aeabadf /src/map/unit.c | |
parent | 60cfb9545fbfa1301d147ba242a8048a0fbde758 (diff) | |
download | hercules-038174e232c03519474f86e5738cecac34bbdee3.tar.gz hercules-038174e232c03519474f86e5738cecac34bbdee3.tar.bz2 hercules-038174e232c03519474f86e5738cecac34bbdee3.tar.xz hercules-038174e232c03519474f86e5738cecac34bbdee3.zip |
Also fixed a behavior of npcwalkto, which was capped by walkpath limit.
Signed-off-by: Matheus Macabu <mkbu95@gmail.com>
Diffstat (limited to 'src/map/unit.c')
-rw-r--r-- | src/map/unit.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/unit.c b/src/map/unit.c index 15421019b..952b1a20e 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -330,7 +330,7 @@ int unit_walktoxy( struct block_list *bl, short x, short y, int flag) && wpd.path_len > 14 ) // Official number of walkable cells is 14 if and only if there is an obstacle between. [malufett] return 0; #endif - if( battle_config.max_walk_path < wpd.path_len ) + if( (battle_config.max_walk_path < wpd.path_len) && (bl->type != BL_NPC) ) return 0; if (flag&4 && DIFF_TICK(ud->canmove_tick, gettick()) > 0 && |