From 52d5ee2941bb0e33f49a7092d8ec32ee8e0fd54e Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 29 Nov 2014 01:09:38 +0300 Subject: Use server feature haveNpcGender. --- src/net/eathena/beinghandler.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/net/eathena') diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp index 7736c5298..ad3614015 100644 --- a/src/net/eathena/beinghandler.cpp +++ b/src/net/eathena/beinghandler.cpp @@ -41,6 +41,8 @@ #include "gui/windows/outfitwindow.h" +#include "net/serverfeatures.h" + #include "net/ea/eaprotocol.h" #include "net/eathena/messageout.h" @@ -1051,7 +1053,8 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg) // if (!mHideShield) // setSprite(dstBeing, SPRITE_SHIELD, shield); } - else if (dstBeing->getType() == ActorType::Npc) + else if (dstBeing->getType() == ActorType::Npc + && serverFeatures->haveNpcGender()) { dstBeing->setGender(Being::intToGender(gender)); } @@ -1215,7 +1218,8 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg) // if (!mHideShield) // setSprite(dstBeing, SPRITE_SHIELD, shield); } - else if (dstBeing->getType() == ActorType::Npc) + else if (dstBeing->getType() == ActorType::Npc + && serverFeatures->haveNpcGender()) { dstBeing->setGender(Being::intToGender(gender)); } @@ -1381,7 +1385,8 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg) // if (!mHideShield) // setSprite(dstBeing, SPRITE_SHIELD, shield); } - else if (dstBeing->getType() == ActorType::Npc) + else if (dstBeing->getType() == ActorType::Npc + && serverFeatures->haveNpcGender()) { dstBeing->setGender(Being::intToGender(gender)); } -- cgit v1.2.3-70-g09d2