mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 07:37:01 +00:00
Correctly select GM level in case heroic class.
Signed-off-by: bloutix <bloutix@getmangos.com> Move heroic class starting level to mangos.conf Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
c798318b7b
commit
f5c4fe86e8
4 changed files with 30 additions and 7 deletions
|
|
@ -599,16 +599,19 @@ bool Player::Create( uint32 guidlow, const std::string& name, uint8 race, uint8
|
|||
}
|
||||
|
||||
// set starting level
|
||||
uint32 start_level = getClass() != CLASS_DEATH_KNIGHT
|
||||
? sWorld.getConfig(CONFIG_START_PLAYER_LEVEL)
|
||||
: sWorld.getConfig(CONFIG_START_HEROIC_PLAYER_LEVEL);
|
||||
|
||||
if (GetSession()->GetSecurity() >= SEC_MODERATOR)
|
||||
SetUInt32Value(UNIT_FIELD_LEVEL, sWorld.getConfig(CONFIG_START_GM_LEVEL));
|
||||
else
|
||||
{
|
||||
if(getClass() == CLASS_DEATH_KNIGHT)
|
||||
SetUInt32Value(UNIT_FIELD_LEVEL, 55);
|
||||
else
|
||||
SetUInt32Value(UNIT_FIELD_LEVEL, sWorld.getConfig(CONFIG_START_PLAYER_LEVEL));
|
||||
uint32 gm_level = sWorld.getConfig(CONFIG_START_GM_LEVEL);
|
||||
if(gm_level > start_level)
|
||||
start_level = gm_level;
|
||||
}
|
||||
|
||||
SetUInt32Value(UNIT_FIELD_LEVEL, start_level);
|
||||
|
||||
InitRunes();
|
||||
|
||||
SetUInt32Value (PLAYER_FIELD_COINAGE, sWorld.getConfig(CONFIG_START_PLAYER_MONEY));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue