summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2014-03-29 17:53:25 -0300
committershennetsind <ind@henn.et>2014-03-29 17:53:25 -0300
commitf0fc96a130ac67d894e44e922504504587b53bb3 (patch)
tree122b77ad1addd17849a9c4e404a00d42d5a51beb
parent336b818cd4acc771563d4ab0d98566de25794143 (diff)
downloadhercules-f0fc96a130ac67d894e44e922504504587b53bb3.tar.gz
hercules-f0fc96a130ac67d894e44e922504504587b53bb3.tar.bz2
hercules-f0fc96a130ac67d894e44e922504504587b53bb3.tar.xz
hercules-f0fc96a130ac67d894e44e922504504587b53bb3.zip
Fixed Issue 8062
Upon death attached (if any) script's execution only terminates if there is a open dialog, allowing silent npcs to remain running. Special Thanks to Haru, AnnieRuru! http://hercules.ws/board/tracker/issue-8062-when-player-died-the-script-execution-stops/ Signed-off-by: shennetsind <ind@henn.et>
-rw-r--r--src/map/pc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index d9b7ea7e1..268125ae1 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -6885,7 +6885,7 @@ int pc_dead(struct map_session_data *sd,struct block_list *src) {
npc->script_event(sd,NPCE_DIE);
// Clear anything NPC-related when you die and was interacting with one.
- if (sd->npc_id || sd->npc_shopid) {
+ if ( (sd->npc_id || sd->npc_shopid) && sd->state.dialog) {
if (sd->state.using_fake_npc) {
clif->clearunit_single(sd->npc_id, CLR_OUTSIGHT, sd->fd);
sd->state.using_fake_npc = 0;