diff options
author | Jared Adams <jaxad0127@gmail.com> | 2010-04-13 22:48:28 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2010-04-16 17:42:45 -0600 |
commit | 11a6f342e579c26320334b9ae9735701386e3b25 (patch) | |
tree | 5de9a3647f881a1f27f4dc31054ad086bdc86d84 /src/net/ea | |
parent | 9f6c1f0bd9d2ef9a3be35fee2c488d8ea6c09d6d (diff) | |
download | mana-client-11a6f342e579c26320334b9ae9735701386e3b25.tar.gz mana-client-11a6f342e579c26320334b9ae9735701386e3b25.tar.bz2 mana-client-11a6f342e579c26320334b9ae9735701386e3b25.tar.xz mana-client-11a6f342e579c26320334b9ae9735701386e3b25.zip |
Add race support for eAthena
The job/class field is used to select the race. If the given race isn't defined,
it falls back on the first race (so servers can use jobs/classes without races).
Also rename job to subtype for Being and subclasses, and begin support for
changing monster and NPC subtypes on the fly (particle effects still need to be
reset when they change).
Reviewed-by: Bertram
Diffstat (limited to 'src/net/ea')
-rw-r--r-- | src/net/ea/beinghandler.cpp | 4 | ||||
-rw-r--r-- | src/net/ea/charserverhandler.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp index 6dcf9631..649e93e8 100644 --- a/src/net/ea/beinghandler.cpp +++ b/src/net/ea/beinghandler.cpp @@ -167,7 +167,7 @@ void BeingHandler::handleMessage(Net::MessageIn &msg) if (speed == 0) { speed = 150; } dstBeing->setWalkSpeed(Vector(speed, speed, 0)); - dstBeing->setJob(job); + dstBeing->setSubtype(job); hairStyle = msg.readInt16(); weapon = msg.readInt16(); headBottom = msg.readInt16(); @@ -550,7 +550,7 @@ void BeingHandler::handleMessage(Net::MessageIn &msg) } dstBeing->setWalkSpeed(Vector(speed, speed, 0)); - dstBeing->setJob(job); + dstBeing->setSubtype(job); hairStyle = msg.readInt16(); weapon = msg.readInt16(); shield = msg.readInt16(); diff --git a/src/net/ea/charserverhandler.cpp b/src/net/ea/charserverhandler.cpp index 64e1d427..8706727a 100644 --- a/src/net/ea/charserverhandler.cpp +++ b/src/net/ea/charserverhandler.cpp @@ -220,7 +220,7 @@ LocalPlayer *CharServerHandler::readPlayerData(Net::MessageIn &msg, int *slot) tempPlayer->setMP(msg.readInt16()); tempPlayer->setMaxMP(msg.readInt16()); msg.readInt16(); // speed - msg.readInt16(); // class + tempPlayer->setSubtype(msg.readInt16()); // class (used for race) int hairStyle = msg.readInt16(); Uint16 weapon = msg.readInt16(); tempPlayer->setSprite(SPRITE_WEAPON, weapon, "", true); |