mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-15 18:10:26 +00:00
feat(Core/LFG): move the LFG max kick count & kick prevention timers … (#8683)
This commit is contained in:
@@ -12183,9 +12183,13 @@ PartyResult Player::CanUninviteFromGroup(ObjectGuid targetPlayerGUID) const
|
||||
|
||||
if (Player* target = ObjectAccessor::FindConnectedPlayer(targetPlayerGUID))
|
||||
{
|
||||
if (target->HasAura(lfg::LFG_SPELL_DUNGEON_COOLDOWN))
|
||||
if (Aura* dungeonCooldownAura = target->GetAura(lfg::LFG_SPELL_DUNGEON_COOLDOWN))
|
||||
{
|
||||
return ERR_PARTY_LFG_BOOT_NOT_ELIGIBLE_S;
|
||||
int32 elapsedTime = dungeonCooldownAura->GetMaxDuration() - dungeonCooldownAura->GetDuration();
|
||||
if (static_cast<int32>(sWorld->getIntConfig(CONFIG_LFG_KICK_PREVENTION_TIMER)) > elapsedTime)
|
||||
{
|
||||
return ERR_PARTY_LFG_BOOT_NOT_ELIGIBLE_S;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user