summaryrefslogtreecommitdiff
path: root/src/map/status.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-12-07 18:47:55 +0300
committerAndrei Karas <akaras@inbox.ru>2014-12-16 22:44:20 +0300
commit3a0bded54bcc5390bf6cd4be9e53206e1bc9e5c2 (patch)
tree55e0658924aed6ed0ac73ca2d4d3391ce5e79fbe /src/map/status.c
parent61d6c958d5a753904d32ef2057b50f426bb0f3b9 (diff)
downloadhercules-3a0bded54bcc5390bf6cd4be9e53206e1bc9e5c2.tar.gz
hercules-3a0bded54bcc5390bf6cd4be9e53206e1bc9e5c2.tar.bz2
hercules-3a0bded54bcc5390bf6cd4be9e53206e1bc9e5c2.tar.xz
hercules-3a0bded54bcc5390bf6cd4be9e53206e1bc9e5c2.zip
Add function what called if player leave npc area.
Diffstat (limited to 'src/map/status.c')
-rw-r--r--src/map/status.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/map/status.c b/src/map/status.c
index 54b4a4358..e0d8d4f9b 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -10466,8 +10466,12 @@ int status_change_end_(struct block_list* bl, enum sc_type type, int tid, const
if(opt_flag&4) //Out of hiding, invoke on place.
skill->unit_move(bl,timer->gettick(),1);
- if(opt_flag&2 && sd && map->getcell(bl->m,bl->x,bl->y,CELL_CHKNPC))
- npc->touch_areanpc(sd,bl->m,bl->x,bl->y); //Trigger on-touch event.
+ if (opt_flag & 2 && sd) {
+ if (map->getcell(bl->m,bl->x,bl->y,CELL_CHKNPC))
+ npc->touch_areanpc(sd,bl->m,bl->x,bl->y); //Trigger on-touch event.
+ else
+ npc->untouch_areanpc(sd, bl->m, bl->x, bl->y);
+ }
ers_free(status->data_ers, sce);
return 1;