mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
lfg related
This commit is contained in:
@@ -36,16 +36,16 @@ PlayerbotSecurityLevel PlayerbotSecurity::LevelFor(Player* from, DenyReason* rea
|
||||
return PLAYERBOT_SECURITY_DENY_ALL;
|
||||
}
|
||||
|
||||
if (sLFGMgr->GetState(bot->GetGUID()) != lfg::LFG_STATE_NONE)
|
||||
{
|
||||
if (!bot->GetGuildId() || bot->GetGuildId() != from->GetGuildId())
|
||||
{
|
||||
if (reason)
|
||||
*reason = PLAYERBOT_DENY_LFG;
|
||||
// if (sLFGMgr->GetState(bot->GetGUID()) != lfg::LFG_STATE_NONE)
|
||||
// {
|
||||
// if (!bot->GetGuildId() || bot->GetGuildId() != from->GetGuildId())
|
||||
// {
|
||||
// if (reason)
|
||||
// *reason = PLAYERBOT_DENY_LFG;
|
||||
|
||||
return PLAYERBOT_SECURITY_TALK;
|
||||
}
|
||||
}
|
||||
// return PLAYERBOT_SECURITY_TALK;
|
||||
// }
|
||||
// }
|
||||
|
||||
Group* group = from->GetGroup();
|
||||
if (group)
|
||||
|
||||
@@ -250,8 +250,8 @@ bool LfgRoleCheckAction::Execute(Event event)
|
||||
{
|
||||
uint32 currentRoles = sLFGMgr->GetRoles(bot->GetGUID());
|
||||
uint32 newRoles = GetRoles();
|
||||
// if (currentRoles == newRoles)
|
||||
// return false;
|
||||
if (currentRoles == newRoles)
|
||||
return false;
|
||||
|
||||
sLFGMgr->SetRoles(bot->GetGUID(), newRoles);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user