From 00a9e49121dfdd706607ceb35fc4dcba4ffbf80c Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 16 Sep 2014 20:53:20 +0300 Subject: Fix some server features usage. --- src/net/tmwa/charserverhandler.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/net/tmwa/charserverhandler.cpp') diff --git a/src/net/tmwa/charserverhandler.cpp b/src/net/tmwa/charserverhandler.cpp index b9997320a..132fd0cea 100644 --- a/src/net/tmwa/charserverhandler.cpp +++ b/src/net/tmwa/charserverhandler.cpp @@ -33,6 +33,7 @@ #include "net/character.h" #include "net/logindata.h" #include "net/net.h" +#include "net/serverfeatures.h" #include "net/tmwa/attrs.h" #include "net/tmwa/gamehandler.h" @@ -279,11 +280,11 @@ void CharServerHandler::newCharacter(const std::string &name, const int slot, outMsg.writeInt8(static_cast(hairColor), "hair color"); outMsg.writeInt8(0, "unused"); outMsg.writeInt8(static_cast(hairstyle), "hair style"); - if (serverVersion >= 9) + if (Net::getServerFeatures()->haveLookSelection()) outMsg.writeInt8(look, "look"); else outMsg.writeInt8(0, "unused"); - if (serverVersion >= 2) + if (Net::getServerFeatures()->haveRaceSelection()) outMsg.writeInt8(race, "class"); } -- cgit v1.2.3-60-g2f50