diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-03-28 11:22:46 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-03-28 11:22:46 -0600 |
commit | df095c66fdf7af74849454dbf8c4c2284616ecd7 (patch) | |
tree | d078ea9ecffd75ab1b526993c5e18846bf501867 /src/net/tmwserv | |
parent | 42a095de15649f0f00ef6c681268d6623205900c (diff) | |
download | mana-client-df095c66fdf7af74849454dbf8c4c2284616ecd7.tar.gz mana-client-df095c66fdf7af74849454dbf8c4c2284616ecd7.tar.bz2 mana-client-df095c66fdf7af74849454dbf8c4c2284616ecd7.tar.xz mana-client-df095c66fdf7af74849454dbf8c4c2284616ecd7.zip |
Remove #ifdefs related to Being creation
Also move the Monster type offset handling into the eAthena netcode.
Diffstat (limited to 'src/net/tmwserv')
-rw-r--r-- | src/net/tmwserv/beinghandler.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/net/tmwserv/beinghandler.cpp b/src/net/tmwserv/beinghandler.cpp index 1a1744cc..08847d7d 100644 --- a/src/net/tmwserv/beinghandler.cpp +++ b/src/net/tmwserv/beinghandler.cpp @@ -139,7 +139,7 @@ void BeingHandler::handleBeingEnterMessage(MessageIn &msg) } else { - being = beingManager->createBeing(id, type, 0); + being = beingManager->createBeing(id, Being::PLAYER, 0); being->setName(name); } Player *p = static_cast< Player * >(being); @@ -154,7 +154,8 @@ void BeingHandler::handleBeingEnterMessage(MessageIn &msg) case OBJECT_NPC: { int subtype = msg.readInt16(); - being = beingManager->createBeing(id, type, subtype); + being = beingManager->createBeing(id, type == OBJECT_MONSTER ? + Being::MONSTER : Being::NPC, subtype); std::string name = msg.readString(); if (name.length() > 0) being->setName(name); } break; |