Information
Added the ability to turn off the info sent to the player.
This commit is contained in:
parent
f8e7eabde4
commit
3b86494671
2 changed files with 13 additions and 2 deletions
|
|
@ -1,5 +1,10 @@
|
|||
[worldserver]
|
||||
|
||||
##
|
||||
# Print information to the player about the amount of extra gold that got deposited to the guild bank
|
||||
GuildFunds.ShowInfo = 1
|
||||
##
|
||||
|
||||
##
|
||||
# The amount, in percentage, of money looted to add to the guild bank
|
||||
# Set to 0 to disable
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
#include "Player.h"
|
||||
#include "ScriptMgr.h"
|
||||
|
||||
bool showInfo;
|
||||
uint32 lootFunds;
|
||||
uint32 questFunds;
|
||||
|
||||
|
|
@ -14,6 +15,7 @@ public:
|
|||
|
||||
void OnAfterConfigLoad(bool /*reload*/) override
|
||||
{
|
||||
showInfo = sConfigMgr->GetOption<bool>("GuildFunds.ShowInfo", 1);
|
||||
lootFunds = sConfigMgr->GetOption<uint32>("GuildFunds.Looted", 10);
|
||||
questFunds = sConfigMgr->GetOption<uint32>("GuildFunds.Quests", 3);
|
||||
}
|
||||
|
|
@ -34,6 +36,8 @@ public:
|
|||
return;
|
||||
|
||||
guild->HandleMemberDepositMoney(player->GetSession(), money);
|
||||
|
||||
if (showInfo)
|
||||
PrintGuildFundsInformation(player, money);
|
||||
}
|
||||
}
|
||||
|
|
@ -73,6 +77,8 @@ public:
|
|||
return;
|
||||
|
||||
guild->HandleMemberDepositMoney(player->GetSession(), money);
|
||||
|
||||
if (showInfo)
|
||||
PrintGuildFundsInformation(player, money);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue