diff options
author | gumi <mekolat@users.noreply.github.com> | 2017-08-23 14:50:33 -0400 |
---|---|---|
committer | gumi <mekolat@users.noreply.github.com> | 2017-08-23 15:15:44 -0400 |
commit | 4a65ddf6c61d72a52d18c9c18e1b405c49c591e9 (patch) | |
tree | 1be4e826661148ebb85c3052aeeed62d0ad96528 /src/emap/script_buildins.c | |
parent | dee2b1a29dc3af07bb434ab986aa552e8be5e26c (diff) | |
download | evol-hercules-closedialog.tar.gz evol-hercules-closedialog.tar.bz2 evol-hercules-closedialog.tar.xz evol-hercules-closedialog.zip |
remove buildin_closedialog, partly add it to buildin_closeclientdialog for backward-compatibilityclosedialog
Diffstat (limited to 'src/emap/script_buildins.c')
-rw-r--r-- | src/emap/script_buildins.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/emap/script_buildins.c b/src/emap/script_buildins.c index 4c32a9a..d888b22 100644 --- a/src/emap/script_buildins.c +++ b/src/emap/script_buildins.c @@ -179,17 +179,19 @@ BUILDIN(npcTalk3) return true; } -BUILDIN(closeDialog) -{ - getSD(); - send_npccommand(sd, st->oid, 5); - return true; -} - BUILDIN(closeClientDialog) { getSD(); - send_npccommand(sd, st->oid, 14); + struct SessionExt *data = session_get_bysd(sd); + + if (data->clientVersion < 19) + { + send_npccommand(sd, st->oid, 5); + } + else + { + send_npccommand(sd, st->oid, 14); + } return true; } |