summaryrefslogtreecommitdiff
path: root/src/net/ea
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-09-04 20:07:08 +0300
committerAndrei Karas <akaras@inbox.ru>2016-09-04 20:07:08 +0300
commit4b53e78ab06a4a717470a76de707cbba9d0aab18 (patch)
tree694936774d7f5237f0b7a18f3806a4c46d283765 /src/net/ea
parent423385491fbfc0df9b01f6e7cb7af0d995154a6a (diff)
downloadplus-4b53e78ab06a4a717470a76de707cbba9d0aab18.tar.gz
plus-4b53e78ab06a4a717470a76de707cbba9d0aab18.tar.bz2
plus-4b53e78ab06a4a717470a76de707cbba9d0aab18.tar.xz
plus-4b53e78ab06a4a717470a76de707cbba9d0aab18.zip
Add support for close only client side window without affecting server.
Diffstat (limited to 'src/net/ea')
-rw-r--r--src/net/ea/npcrecv.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/net/ea/npcrecv.cpp b/src/net/ea/npcrecv.cpp
index ad3a6da10..047d9ca50 100644
--- a/src/net/ea/npcrecv.cpp
+++ b/src/net/ea/npcrecv.cpp
@@ -211,6 +211,20 @@ void NpcRecv::processNpcCommand(Net::MessageIn &msg)
mDialog->itemCraftRequest(invSize);
break;
}
+ case 14:
+ {
+ const NpcDialogs::iterator it = NpcDialog::mNpcDialogs.find(npcId);
+ if (it != NpcDialog::mNpcDialogs.end())
+ {
+ NpcDialog *const dialog = (*it).second;
+ if (dialog)
+ dialog->close();
+ if (dialog == Ea::NpcRecv::mDialog)
+ Ea::NpcRecv::mDialog = nullptr;
+ NpcDialog::mNpcDialogs.erase(it);
+ }
+ break;
+ }
default:
UNIMPLIMENTEDPACKETFIELD(cmd);
break;