summaryrefslogtreecommitdiff
path: root/src/map/clif.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-25 14:32:56 +0300
committerAndrei Karas <akaras@inbox.ru>2015-08-05 14:28:30 +0300
commit81d0eb8441fa7d1bcfde8a1ca9bf09666d5139d8 (patch)
tree12d608e3dd6fd989ca6c46bb988fe91f54630976 /src/map/clif.c
parentac9dc43ac589e0c70f1f4f27d04dad0a302805bc (diff)
downloadhercules-81d0eb8441fa7d1bcfde8a1ca9bf09666d5139d8.tar.gz
hercules-81d0eb8441fa7d1bcfde8a1ca9bf09666d5139d8.tar.bz2
hercules-81d0eb8441fa7d1bcfde8a1ca9bf09666d5139d8.tar.xz
hercules-81d0eb8441fa7d1bcfde8a1ca9bf09666d5139d8.zip
Add optional parameter to warp script command for prevent stoping npc scripts after warp.
Diffstat (limited to 'src/map/clif.c')
-rw-r--r--src/map/clif.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index cbe22dbb0..d00cac0ee 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -9215,14 +9215,16 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) {
clif->updatestatus(sd,SP_DEX);
clif->updatestatus(sd,SP_LUK);
- // abort currently running script
- sd->state.using_fake_npc = 0;
- sd->state.menu_or_input = 0;
- sd->npc_menu = 0;
-
- if(sd->npc_id)
- npc->event_dequeue(sd);
-
+ if (sd->state.warp_clean) {
+ // abort currently running script
+ sd->state.using_fake_npc = 0;
+ sd->state.menu_or_input = 0;
+ sd->npc_menu = 0;
+ if(sd->npc_id)
+ npc->event_dequeue(sd);
+ } else {
+ sd->state.warp_clean = 1;
+ }
if( sd->guild && ( battle_config.guild_notice_changemap == 2 || ( battle_config.guild_notice_changemap == 1 && sd->state.changemap ) ) )
clif->guild_notice(sd,sd->guild);
}