From d93a829a1384d73247201101b20cf97a49a71b75 Mon Sep 17 00:00:00 2001 From: shennetsind Date: Wed, 14 Dec 2011 21:25:58 +0000 Subject: unit_blown now returns number of moved cells, bugreport:4985 git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15116 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/unit.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/map') diff --git a/src/map/unit.c b/src/map/unit.c index 0225b4b87..0b6e098a9 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -686,7 +686,11 @@ int unit_blown(struct block_list* bl, int dx, int dy, int count, int flag) if(dx || dy) { map_foreachinmovearea(clif_outsight, bl, AREA_SIZE, dx, dy, bl->type == BL_PC ? BL_ALL : BL_PC, bl); - + + count = distance_xy(bl->x,bl->y,dx,dy); + if( count < 0 ) + count = -count; + if(su) { skill_unit_move_unit_group(su->group, bl->m, dx, dy); -- cgit v1.2.3-70-g09d2