summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/map/skill.c2
-rw-r--r--src/map/unit.c5
2 files changed, 6 insertions, 1 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index b66faaf52..d6ea76dfc 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -4257,7 +4257,7 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
}
clif_skill_nodamage(src,bl,TK_HIGHJUMP,skilllv,1);
- if(map_getcell(src->m,x,y,CELL_CHKPASS)) {
+ if(map_count_oncell(src->m,x,y,BL_PC|BL_NPC|BL_MOB)) {
clif_slide(src,x,y);
unit_movepos(src, x, y, 1, 0);
}
diff --git a/src/map/unit.c b/src/map/unit.c
index 252b65188..fa6c075db 100644
--- a/src/map/unit.c
+++ b/src/map/unit.c
@@ -420,6 +420,11 @@ int unit_run(struct block_list *bl)
{
if(!map_getcell(bl->m,to_x+dir_x,to_y+dir_y,CELL_CHKPASS))
break;
+
+ //if sprinting and there's a PC/Mob/NPC, block the path [Kevin]
+ if(sc->data[SC_RUN] && map_count_oncell(bl->m, to_x+dir_x, to_y+dir_y, BL_PC|BL_MOB|BL_NPC))
+ break;
+
to_x += dir_x;
to_y += dir_y;
}