summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authormalufett <malufett.eat.my.binaries@gmail.com>2014-12-14 21:47:22 +0800
committermalufett <malufett.eat.my.binaries@gmail.com>2014-12-14 21:47:22 +0800
commitfe7734dcb4ee15221b5dd006ea269ddf2f42e4b2 (patch)
tree1ca05d3fc5e762cc530ae090cf3b34c746105e1d /src/map/skill.c
parentff145549f389e63be01234ddf778905700883d20 (diff)
downloadhercules-fe7734dcb4ee15221b5dd006ea269ddf2f42e4b2.tar.gz
hercules-fe7734dcb4ee15221b5dd006ea269ddf2f42e4b2.tar.bz2
hercules-fe7734dcb4ee15221b5dd006ea269ddf2f42e4b2.tar.xz
hercules-fe7734dcb4ee15221b5dd006ea269ddf2f42e4b2.zip
Fixed Bug#8456
-http://hercules.ws/board/tracker/issue-8456-map-crash-skill-cell-overlap/?gopid=24193 Signed-off-by: malufett <malufett.eat.my.binaries@gmail.com>
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index eb7394b9e..d89d82f57 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -10107,11 +10107,13 @@ int skill_castend_pos2(struct block_list* src, int x, int y, uint16 skill_id, ui
}
case MG_SAFETYWALL:
- if (map->foreachincell(skill->cell_overlap,src->m,x,y,BL_SKILL)) {
- skill->unitsetting(src,skill_id,skill_lv,x,y,0);
+ {
+ int alive = 1;
+ if ( map->foreachincell(skill->cell_overlap, src->m, x, y, BL_SKILL, skill_id, &alive, src) ) {
+ skill->unitsetting(src, skill_id, skill_lv, x, y, 0);
return 0; // Don't consume gems if cast on LP
}
-
+ }
case MG_FIREWALL:
case MG_THUNDERSTORM: