mirror of
https://gitcode.com/GitHub_Trending/az/azerothcore-wotlk.git
synced 2026-10-10 15:16:38 +08:00
fix(Core/Guilds): Implement guild bank gold limit matching client (#9666)
Co-authored-by: Shauren <[email protected]>
This commit is contained in:
@@ -1628,6 +1628,12 @@ void Guild::HandleMemberDepositMoney(WorldSession* session, uint32 amount)
|
||||
// Call script after validation and before money transfer.
|
||||
sScriptMgr->OnGuildMemberDepositMoney(this, player, amount);
|
||||
|
||||
if (m_bankMoney > GUILD_BANK_MONEY_LIMIT - amount)
|
||||
{
|
||||
SendCommandResult(session, GUILD_COMMAND_MOVE_ITEM, ERR_GUILD_BANK_FULL);
|
||||
return;
|
||||
}
|
||||
|
||||
CharacterDatabaseTransaction trans = CharacterDatabase.BeginTransaction();
|
||||
_ModifyBankMoney(trans, amount, true);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user