diff options
author | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2011-03-17 23:13:27 +0100 |
---|---|---|
committer | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2011-11-01 17:16:08 +0100 |
commit | 53c4a583daee08a452c26bebbf6308d47415cecb (patch) | |
tree | 3414302b01ace616df6203006bc5bb4bd1bf1269 /src | |
parent | 4e0cd127c49f9d209ed45ab620a7cccb4f608950 (diff) | |
download | manaserv-53c4a583daee08a452c26bebbf6308d47415cecb.tar.gz manaserv-53c4a583daee08a452c26bebbf6308d47415cecb.tar.bz2 manaserv-53c4a583daee08a452c26bebbf6308d47415cecb.tar.xz manaserv-53c4a583daee08a452c26bebbf6308d47415cecb.zip |
Removed some superfluous new character initializations
The level, character points and correction points are already
initialized by the Character constructor.
The ATTR_GP attribute is either not present, or obtained default value
from mDefaultAttributes. In both cases it makes no sense to set it to 0.
Reviewed-by: Yohann Ferreira
Diffstat (limited to 'src')
-rw-r--r-- | src/account-server/accounthandler.cpp | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/account-server/accounthandler.cpp b/src/account-server/accounthandler.cpp index f5779083..9978956f 100644 --- a/src/account-server/accounthandler.cpp +++ b/src/account-server/accounthandler.cpp @@ -800,19 +800,6 @@ void AccountHandler::handleCharacterCreateMessage(AccountClient &client, mDefaultAttributes.end()); newCharacter->setAccount(acc); newCharacter->setCharacterSlot(slot); - newCharacter->setLevel(1); - - // Init GP value to avoid flawed ones. - AttributeMap::iterator itr = - newCharacter->mAttributes.find(ATTR_GP); - if (itr != newCharacter->mAttributes.end()) - { - itr->second.base = 0; - itr->second.modified = 0; - } - - newCharacter->setCharacterPoints(0); - newCharacter->setCorrectionPoints(0); newCharacter->setGender(gender); newCharacter->setHairStyle(hairStyle); newCharacter->setHairColor(hairColor); |