summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-03-19 01:46:29 +0300
committerAndrei Karas <akaras@inbox.ru>2015-03-19 01:46:29 +0300
commitd6b553b99c602f20dd3183a0a12861e5d25941db (patch)
tree3cd583ddba5e1ad8d1ba0b8edd98cf411f05c861 /src/net/eathena
parent88735abcdaf6e25a008f76c9a82730e8be9773f8 (diff)
downloadmv-d6b553b99c602f20dd3183a0a12861e5d25941db.tar.gz
mv-d6b553b99c602f20dd3183a0a12861e5d25941db.tar.bz2
mv-d6b553b99c602f20dd3183a0a12861e5d25941db.tar.xz
mv-d6b553b99c602f20dd3183a0a12861e5d25941db.zip
eathena: add partial support for packet SMSG_BEING_VIEW_EQUIPMENT 0x0997.
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/beinghandler.cpp37
-rw-r--r--src/net/eathena/beinghandler.h2
-rw-r--r--src/net/eathena/packets.h2
-rw-r--r--src/net/eathena/protocol.h1
4 files changed, 41 insertions, 1 deletions
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index 798506991..74dabe61a 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -133,6 +133,7 @@ BeingHandler::BeingHandler(const bool enableSync) :
SMSG_BEING_FONT,
SMSG_BEING_MILLENIUM_SHIELD,
SMSG_BEING_CHARM,
+ SMSG_BEING_VIEW_EQUIPMENT,
0
};
handledMessages = _messages;
@@ -397,6 +398,10 @@ void BeingHandler::handleMessage(Net::MessageIn &msg)
processBeingCharm(msg);
break;
+ case SMSG_BEING_VIEW_EQUIPMENT:
+ processBeingViewEquipment(msg);
+ break;
+
default:
break;
}
@@ -1884,4 +1889,36 @@ void BeingHandler::processBeingCharm(Net::MessageIn &msg)
msg.readInt16("charm count");
}
+void BeingHandler::processBeingViewEquipment(Net::MessageIn &msg)
+{
+ UNIMPLIMENTEDPACKET;
+
+ const int count = (msg.readInt16("len") - 45) / 31;
+ msg.readString(24, "name");
+ msg.readInt16("job");
+ msg.readInt16("head");
+ msg.readInt16("accessory");
+ msg.readInt16("accessory2");
+ msg.readInt16("accessory3");
+ msg.readInt16("robe");
+ msg.readInt16("hair color");
+ msg.readInt16("body color");
+ msg.readUInt8("gender");
+ for (int f = 0; f < count; f ++)
+ {
+ msg.readInt16("index");
+ msg.readInt16("item id");
+ msg.readUInt8("item type");
+ msg.readInt32("location");
+ msg.readInt32("wear state");
+ msg.readInt8("refine");
+ for (int d = 0; d < 4; d ++)
+ msg.readInt16("card");
+ msg.readInt32("hire expire date (?)");
+ msg.readInt16("equip type");
+ msg.readInt16("item sprite number");
+ msg.readUInt8("flags");
+ }
+}
+
} // namespace EAthena
diff --git a/src/net/eathena/beinghandler.h b/src/net/eathena/beinghandler.h
index 7e673a863..6acafb931 100644
--- a/src/net/eathena/beinghandler.h
+++ b/src/net/eathena/beinghandler.h
@@ -158,6 +158,8 @@ class BeingHandler final : public MessageHandler, public Ea::BeingHandler
static void processBeingMilleniumShield(Net::MessageIn &msg);
static void processBeingCharm(Net::MessageIn &msg);
+
+ static void processBeingViewEquipment(Net::MessageIn &msg);
};
} // namespace EAthena
diff --git a/src/net/eathena/packets.h b/src/net/eathena/packets.h
index 3ed20e5fa..a8bf6dc50 100644
--- a/src/net/eathena/packets.h
+++ b/src/net/eathena/packets.h
@@ -248,7 +248,7 @@ int16_t packet_lengths[] =
31, 0, 0, 0, 0, 0, 0, 14, 0, 0, -1, 0, 0, 288, 12, 0,
// #0x0980
0, 0, 0, 29, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 31, -1, -1, -1, -1, -1, -1, 0, 0, 11, 9, 8, 0, -1, 0, 0,
+ 31, -1, -1, -1, -1, -1, -1, -1, 0, 11, 9, 8, 0, -1, 0, 0,
0, 0, 0, 0, 0, 0, 12, 0, 16, 0, 16, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
// #0x09C0
diff --git a/src/net/eathena/protocol.h b/src/net/eathena/protocol.h
index 5fb5b9ba0..2cc614d3b 100644
--- a/src/net/eathena/protocol.h
+++ b/src/net/eathena/protocol.h
@@ -167,6 +167,7 @@
#define SMSG_BEING_ATTRS 0x0b0a
#define SMSG_BEING_FONT 0x02ef
#define SMSG_BEING_MILLENIUM_SHIELD 0x0440
+#define SMSG_BEING_VIEW_EQUIPMENT 0x0997
#define SMSG_IGNORE_NICK_ACK 0x00d1
#define SMSG_STARS_KILL 0x020e
#define SMSG_GLADIATOR_FEEL_REQUEST 0x0253