summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/protocol.h2
-rw-r--r--src/net/eathena/vendinghandler.cpp6
-rw-r--r--src/net/eathena/vendinghandler.h2
3 files changed, 10 insertions, 0 deletions
diff --git a/src/net/eathena/protocol.h b/src/net/eathena/protocol.h
index 0d3954d7b..a6f14c109 100644
--- a/src/net/eathena/protocol.h
+++ b/src/net/eathena/protocol.h
@@ -533,4 +533,6 @@
#define CMSG_AUCTION_SEARCH 0x0251
#define CMSG_AUCTION_BUY_SELL 0x025c
+#define CMSG_VENDING_CLOSE 0x012e
+
#endif // NET_EATHENA_PROTOCOL_H
diff --git a/src/net/eathena/vendinghandler.cpp b/src/net/eathena/vendinghandler.cpp
index 991bcdf10..dd1d7e7cc 100644
--- a/src/net/eathena/vendinghandler.cpp
+++ b/src/net/eathena/vendinghandler.cpp
@@ -20,6 +20,7 @@
#include "net/eathena/vendinghandler.h"
+#include "net/eathena/messageout.h"
#include "net/eathena/protocol.h"
#include "debug.h"
@@ -151,4 +152,9 @@ void VendingHandler::processReport(Net::MessageIn &msg)
msg.readInt16("amount");
}
+void VendingHandler::close() const
+{
+ createOutPacket(CMSG_VENDING_CLOSE);
+}
+
} // namespace EAthena
diff --git a/src/net/eathena/vendinghandler.h b/src/net/eathena/vendinghandler.h
index d775f7958..cf451e8fa 100644
--- a/src/net/eathena/vendinghandler.h
+++ b/src/net/eathena/vendinghandler.h
@@ -37,6 +37,8 @@ class VendingHandler final : public MessageHandler,
void handleMessage(Net::MessageIn &msg) override final;
+ void close() const override final;
+
protected:
static void processOpenReq(Net::MessageIn &msg);