summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-09 16:57:12 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-09 16:59:43 +0300
commit84b673bf3871970e43f8358728b5c4aedfc3f1e4 (patch)
tree7a9acc90878a1bcdd9424e6f91d0ed1e3bcd33d2 /src/net/eathena
parent0ff1cce3a289c2a813ed5db13250abbb23d2a9f0 (diff)
downloadmanaplus-84b673bf3871970e43f8358728b5c4aedfc3f1e4.tar.gz
manaplus-84b673bf3871970e43f8358728b5c4aedfc3f1e4.tar.bz2
manaplus-84b673bf3871970e43f8358728b5c4aedfc3f1e4.tar.xz
manaplus-84b673bf3871970e43f8358728b5c4aedfc3f1e4.zip
eathena: add packet CMSG_MOVE_TO_CART 0x0126.
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/inventoryhandler.cpp6
-rw-r--r--src/net/eathena/protocol.h2
2 files changed, 8 insertions, 0 deletions
diff --git a/src/net/eathena/inventoryhandler.cpp b/src/net/eathena/inventoryhandler.cpp
index dba668745..7fa96f64e 100644
--- a/src/net/eathena/inventoryhandler.cpp
+++ b/src/net/eathena/inventoryhandler.cpp
@@ -217,6 +217,12 @@ void InventoryHandler::moveItem2(const int source, const int slot,
outMsg.writeInt16(static_cast<int16_t>(slot + STORAGE_OFFSET));
outMsg.writeInt32(amount);
}
+ else if (source == Inventory::INVENTORY && destination == Inventory::CART)
+ {
+ MessageOut outMsg(CMSG_MOVE_TO_CART);
+ outMsg.writeInt16(static_cast<int16_t>(slot + INVENTORY_OFFSET));
+ outMsg.writeInt32(amount);
+ }
}
void InventoryHandler::processPlayerEquipment(Net::MessageIn &msg)
diff --git a/src/net/eathena/protocol.h b/src/net/eathena/protocol.h
index 82b0b0c8d..a27ca6f06 100644
--- a/src/net/eathena/protocol.h
+++ b/src/net/eathena/protocol.h
@@ -280,6 +280,8 @@
#define CSMG_MOVE_FROM_STORAGE 0x0364 /** Remove item from storage */
#define CMSG_CLOSE_STORAGE 0x0193 /** Request storage close */
+#define CMSG_MOVE_TO_CART 0x0126
+
#define CMSG_ADMIN_ANNOUNCE 0x0099
#define CMSG_ADMIN_LOCAL_ANNOUNCE 0x019C
#define CMSG_ADMIN_HIDE 0x019D