mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
Add config option for RND bot trading. (#1132)
* Add config option for RNDbot trading.
This commit is contained in:
@@ -32,6 +32,12 @@ bool TradeStatusAction::Execute(Event event)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sPlayerbotAIConfig->enableRandomBotTrading && sRandomPlayerbotMgr->IsRandomBot(bot))
|
||||
{
|
||||
bot->Whisper("Trading is disabled", LANG_UNIVERSAL, trader);
|
||||
return false;
|
||||
}
|
||||
|
||||
// Allow trades from group members or bots
|
||||
if ((!bot->GetGroup() || !bot->GetGroup()->IsMember(trader->GetGUID())) &&
|
||||
(trader != master || !botAI->GetSecurity()->CheckLevelFor(PLAYERBOT_SECURITY_ALLOW_ALL, true, master)) &&
|
||||
|
||||
Reference in New Issue
Block a user