diff options
-rw-r--r-- | src/net/eathena/itemhandler.cpp | 17 | ||||
-rw-r--r-- | src/net/eathena/itemhandler.h | 2 | ||||
-rw-r--r-- | src/net/eathena/protocol.h | 1 |
3 files changed, 20 insertions, 0 deletions
diff --git a/src/net/eathena/itemhandler.cpp b/src/net/eathena/itemhandler.cpp index f37bb6f09..438a4c146 100644 --- a/src/net/eathena/itemhandler.cpp +++ b/src/net/eathena/itemhandler.cpp @@ -40,6 +40,7 @@ ItemHandler::ItemHandler() : SMSG_ITEM_VISIBLE, SMSG_ITEM_DROPPED, SMSG_ITEM_REMOVE, + SMSG_GRAFFITI_VISIBLE, 0 }; handledMessages = _messages; @@ -61,6 +62,10 @@ void ItemHandler::handleMessage(Net::MessageIn &msg) processItemRemove(msg); break; + case SMSG_GRAFFITI_VISIBLE: + processGraffiti(msg); + break; + default: break; } @@ -85,4 +90,16 @@ void ItemHandler::processItemDropped(Net::MessageIn &msg) } } +void ItemHandler::processGraffiti(Net::MessageIn &msg) +{ + msg.readInt32("graffiti id"); + msg.readInt32("creator id"); + msg.readInt16("x"); + msg.readInt16("y"); + msg.readUInt8("job"); + msg.readUInt8("visible"); + msg.readUInt8("is content"); + msg.readString(80, "text"); +} + } // namespace EAthena diff --git a/src/net/eathena/itemhandler.h b/src/net/eathena/itemhandler.h index 8b453bee4..77b7a6da2 100644 --- a/src/net/eathena/itemhandler.h +++ b/src/net/eathena/itemhandler.h @@ -41,6 +41,8 @@ class ItemHandler final : public MessageHandler, public Ea::ItemHandler protected: static void processItemDropped(Net::MessageIn &msg); + + static void processGraffiti(Net::MessageIn &msg); }; } // namespace EAthena diff --git a/src/net/eathena/protocol.h b/src/net/eathena/protocol.h index d94c8c036..b117e1af0 100644 --- a/src/net/eathena/protocol.h +++ b/src/net/eathena/protocol.h @@ -97,6 +97,7 @@ #define SMSG_SKILL_SNAP 0x08d2 #define SMSG_ITEM_USE_RESPONSE 0x00a8 #define SMSG_ITEM_VISIBLE 0x009d /**< An item is on the floor */ +#define SMSG_GRAFFITI_VISIBLE 0x01c9 #define SMSG_ITEM_DROPPED 0x084b /**< An item is dropped */ #define SMSG_ITEM_REMOVE 0x00a1 /**< An item disappers */ #define SMSG_BEING_VISIBLE 0x0915 |