From 4cfdb3620ccbd0de6bd53c5f22e7b6d3801627bf Mon Sep 17 00:00:00 2001 From: Fate Date: Sat, 1 Nov 2008 22:39:26 +0000 Subject: * Updated GUI table and model to better handle NULL widgets during initialisation * On SMSG_MOVE et al., ignore boots and glove information-- that information is incorrect and we're guaranteed to already have the correct information anyway. * Properly decode `is dead' information for PCs, so that dead players, when encountered, will be lying on the ground, dead, rather than standing. * Use `skills.xml' file from client data to determine skill names * Report client version number (hereby bumped to 1) in unused charserver slot (ignored by vanilla eAthena) --- src/net/beinghandler.cpp | 19 ++++++++++--------- src/net/network.h | 4 ++++ src/net/skillhandler.cpp | 1 + 3 files changed, 15 insertions(+), 9 deletions(-) (limited to 'src/net') diff --git a/src/net/beinghandler.cpp b/src/net/beinghandler.cpp index fa2b6728..1f2463b3 100644 --- a/src/net/beinghandler.cpp +++ b/src/net/beinghandler.cpp @@ -405,8 +405,8 @@ void BeingHandler::handleMessage(MessageIn *msg) headTop = msg->readInt16(); headMid = msg->readInt16(); hairColor = msg->readInt16(); - shoes = msg->readInt16(); // clothes color - "abused" as shoes - gloves = msg->readInt16(); // head dir - "abused" as gloves + msg->readInt16(); // clothes color - Aethyra-"abused" as shoes, we ignore it + msg->readInt16(); // head dir - Aethyra-"abused" as gloves, we ignore it msg->readInt32(); // guild msg->readInt32(); // emblem msg->readInt16(); // manner @@ -419,10 +419,6 @@ void BeingHandler::handleMessage(MessageIn *msg) dstBeing->setSprite(Being::BOTTOMCLOTHES_SPRITE, headBottom); dstBeing->setSprite(Being::TOPCLOTHES_SPRITE, headMid); dstBeing->setSprite(Being::HAT_SPRITE, headTop); - dstBeing->setSprite(Being::SHOE_SPRITE, shoes); - // Compensation for the unpatched TMW server - if (gloves > 10) - dstBeing->setSprite(Being::GLOVES_SPRITE, gloves); dstBeing->setSprite(Being::CAPE_SPRITE, cape); dstBeing->setSprite(Being::MISC1_SPRITE, misc1); dstBeing->setSprite(Being::MISC2_SPRITE, misc2); @@ -447,9 +443,14 @@ void BeingHandler::handleMessage(MessageIn *msg) if (msg->getId() == SMSG_PLAYER_UPDATE_1) { - if (msg->readInt8() == 2) - { - dstBeing->setAction(Being::SIT); + switch (msg->readInt8()) { + + case 1: dstBeing->setAction(Being::DEAD); + break; + + case 2: dstBeing->setAction(Being::SIT); + break; + } } else if (msg->getId() == SMSG_PLAYER_MOVE) diff --git a/src/net/network.h b/src/net/network.h index d6fec761..0326b6ce 100644 --- a/src/net/network.h +++ b/src/net/network.h @@ -29,6 +29,10 @@ #include #include +#define TMW_CLIENT_PROTOCOL_VERSION 1 + /**< Protocol version, reported to the eAthena char and mapserver who + can adjust the protocol accordingly */ + class MessageHandler; class MessageIn; diff --git a/src/net/skillhandler.cpp b/src/net/skillhandler.cpp index 828c2378..53cfda1a 100644 --- a/src/net/skillhandler.cpp +++ b/src/net/skillhandler.cpp @@ -73,6 +73,7 @@ void SkillHandler::handleMessage(MessageIn *msg) } } } + skillDialog->update(); break; case SMSG_SKILL_FAILED: -- cgit v1.2.3-70-g09d2