Core/Players: Introduce configurable allied race starting level and fix default level selection for pandaren death knights

Port From (https://github.com/TrinityCore/TrinityCore/commit/bff8f2ff4ebc4144a2c1c31a65b78a1f0ed3f973)
This commit is contained in:
hondacrx
2020-12-31 15:29:16 -05:00
parent 1ddf80bac3
commit 7432ae56a8
7 changed files with 76 additions and 40 deletions
+1 -1
View File
@@ -101,7 +101,7 @@ namespace Game.Chat
byte oldLevel = (byte)target.GetLevel();
// set starting level
uint startLevel = (uint)(target.GetClass() != Class.Deathknight ? WorldConfig.GetIntValue(WorldCfg.StartPlayerLevel) : WorldConfig.GetIntValue(WorldCfg.StartDeathKnightPlayerLevel));
uint startLevel = target.GetStartLevel(target.GetRace(), target.GetClass());
target._ApplyAllLevelScaleItemMods(false);
target.SetLevel(startLevel);