diff --git a/src/game/Guild.h b/src/game/Guild.h index 8890baf44..90dff2c75 100644 --- a/src/game/Guild.h +++ b/src/game/Guild.h @@ -26,6 +26,14 @@ class Item; +uint32 GuildBankTabPrice[GUILD_BANK_MAX_TABS] = +{ 100,250,500,1000,2500,5000 }; + +inline uint32 GetGuildBankTabPrice(uint8 Index) +{ + return Index < GUILD_BANK_MAX_TABS ? GuildBankTabPrice[Index] : 0; +} + enum GuildDefaultRanks { GR_GUILDMASTER = 0, diff --git a/src/game/GuildHandler.cpp b/src/game/GuildHandler.cpp index 607d469a9..a65435d42 100644 --- a/src/game/GuildHandler.cpp +++ b/src/game/GuildHandler.cpp @@ -1573,7 +1573,7 @@ void WorldSession::HandleGuildBankBuyTab( WorldPacket & recv_data ) if(!pGuild) return; - uint32 TabCost = objmgr.GetGuildBankTabPrice(TabId) * GOLD; + uint32 TabCost = GetGuildBankTabPrice(TabId) * GOLD; if (!TabCost) return; diff --git a/src/game/ObjectMgr.cpp b/src/game/ObjectMgr.cpp index 0cc7d3210..ad1579446 100644 --- a/src/game/ObjectMgr.cpp +++ b/src/game/ObjectMgr.cpp @@ -123,14 +123,6 @@ ObjectMgr::ObjectMgr() m_arenaTeamId = 1; m_auctionid = 1; - mGuildBankTabPrice.resize(GUILD_BANK_MAX_TABS); - mGuildBankTabPrice[0] = 100; - mGuildBankTabPrice[1] = 250; - mGuildBankTabPrice[2] = 500; - mGuildBankTabPrice[3] = 1000; - mGuildBankTabPrice[4] = 2500; - mGuildBankTabPrice[5] = 5000; - // Only zero condition left, others will be added while loading DB tables mConditions.resize(1); } diff --git a/src/game/ObjectMgr.h b/src/game/ObjectMgr.h index 5468f1a17..bf610816e 100644 --- a/src/game/ObjectMgr.h +++ b/src/game/ObjectMgr.h @@ -694,8 +694,6 @@ class ObjectMgr int GetIndexForLocale(LocaleConstant loc); LocaleConstant GetLocaleForIndex(int i); - // guild bank tabs - uint32 GetGuildBankTabPrice(uint8 Index) const { return Index < GUILD_BANK_MAX_TABS ? mGuildBankTabPrice[Index] : 0; } uint16 GetConditionId(ConditionType condition, uint32 value1, uint32 value2); bool IsPlayerMeetToCondition(Player const* player, uint16 condition_id) const @@ -862,9 +860,6 @@ class ObjectMgr RespawnTimes mCreatureRespawnTimes; RespawnTimes mGORespawnTimes; - typedef std::vector GuildBankTabPriceMap; - GuildBankTabPriceMap mGuildBankTabPrice; - // Storage for Conditions. First element (index 0) is reserved for zero-condition (nothing required) typedef std::vector ConditionStore; ConditionStore mConditions; diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index d3177215c..b45ef9aba 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -4363,7 +4363,7 @@ void Aura::HandlePeriodicDamage(bool apply, bool Real) //3 points: ${($m1+$b1*3+0.03*$AP)*6} damage over 12 secs //4 points: ${($m1+$b1*4+0.03428571*$AP)*7} damage over 14 secs //5 points: ${($m1+$b1*5+0.0375*$AP)*8} damage over 16 secs - float AP_per_combo[] = {0, 0.015f, 0.024, 0.03, 0.03428571, 0.0375}; + float AP_per_combo[6] = {0.0f, 0.015f, 0.024f, 0.03f, 0.03428571f, 0.0375f}; uint8 cp = ((Player*)caster)->GetComboPoints(); if (cp > 5) cp = 5; m_modifier.m_amount += int32(caster->GetTotalAttackPowerValue(BASE_ATTACK) * AP_per_combo[cp]); diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 31befeff3..648d7e555 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "7760" + #define REVISION_NR "7761" #endif // __REVISION_NR_H__