mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-21 12:47:07 +00:00
fix(Core/Player): Give Death Knight's twenty silver on character creation (#12974)
* Make sacrifices to workflow god Best note ever ^^
This commit is contained in:
@@ -868,6 +868,14 @@ StartHeroicPlayerLevel = 55
|
||||
|
||||
StartPlayerMoney = 0
|
||||
|
||||
#
|
||||
# StartHeroicPlayerMoney
|
||||
# Description: Amount of money (in Copper) that heroic class characters have after creation.
|
||||
# Default: 2000
|
||||
# 2000 - (20 Silver)
|
||||
|
||||
StartHeroicPlayerMoney = 2000
|
||||
|
||||
#
|
||||
# MaxHonorPoints
|
||||
# Description: Maximum honor points a character can have.
|
||||
|
||||
@@ -569,7 +569,9 @@ bool Player::Create(ObjectGuid::LowType guidlow, CharacterCreateInfo* createInfo
|
||||
|
||||
InitRunes();
|
||||
|
||||
SetUInt32Value(PLAYER_FIELD_COINAGE, sWorld->getIntConfig(CONFIG_START_PLAYER_MONEY));
|
||||
SetUInt32Value(PLAYER_FIELD_COINAGE, getClass() != CLASS_DEATH_KNIGHT
|
||||
? sWorld->getIntConfig(CONFIG_START_PLAYER_MONEY)
|
||||
: sWorld->getIntConfig(CONFIG_START_HEROIC_PLAYER_MONEY));
|
||||
SetHonorPoints(sWorld->getIntConfig(CONFIG_START_HONOR_POINTS));
|
||||
SetArenaPoints(sWorld->getIntConfig(CONFIG_START_ARENA_POINTS));
|
||||
|
||||
|
||||
@@ -231,6 +231,7 @@ enum WorldIntConfigs
|
||||
CONFIG_START_PLAYER_LEVEL,
|
||||
CONFIG_START_HEROIC_PLAYER_LEVEL,
|
||||
CONFIG_START_PLAYER_MONEY,
|
||||
CONFIG_START_HEROIC_PLAYER_MONEY,
|
||||
CONFIG_MAX_HONOR_POINTS,
|
||||
CONFIG_MAX_HONOR_POINTS_MONEY_PER_POINT,
|
||||
CONFIG_START_HONOR_POINTS,
|
||||
|
||||
@@ -848,6 +848,13 @@ void World::LoadConfigSettings(bool reload)
|
||||
m_int_configs[CONFIG_START_PLAYER_MONEY] = 0;
|
||||
}
|
||||
|
||||
m_int_configs[CONFIG_START_HEROIC_PLAYER_MONEY] = sConfigMgr->GetOption<int32>("StartHeroicPlayerMoney", 2000);
|
||||
if (int32(m_int_configs[CONFIG_START_HEROIC_PLAYER_MONEY]) < 0 || int32(m_int_configs[CONFIG_START_HEROIC_PLAYER_MONEY]) > MAX_MONEY_AMOUNT)
|
||||
{
|
||||
LOG_ERROR("server.loading", "StartHeroicPlayerMoney ({}) must be in range 0..{}. Set to {}.", m_int_configs[CONFIG_START_HEROIC_PLAYER_MONEY], MAX_MONEY_AMOUNT, 2000);
|
||||
m_int_configs[CONFIG_START_HEROIC_PLAYER_MONEY] = 2000;
|
||||
}
|
||||
|
||||
m_int_configs[CONFIG_MAX_HONOR_POINTS] = sConfigMgr->GetOption<int32>("MaxHonorPoints", 75000);
|
||||
if (int32(m_int_configs[CONFIG_MAX_HONOR_POINTS]) < 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user