mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 01:37:00 +00:00
[11639] Limit spells 74410 and 74411 only to bg and arenas
This commit is contained in:
parent
b4ec3f3fd9
commit
479cfcf84a
2 changed files with 11 additions and 1 deletions
|
|
@ -3933,6 +3933,16 @@ SpellCastResult SpellMgr::GetSpellAllowedInLocationError(SpellEntry const *spell
|
|||
BattleGround* bg = player->GetBattleGround();
|
||||
return bg && bg->GetStatus()==STATUS_WAIT_JOIN ? SPELL_CAST_OK : SPELL_FAILED_ONLY_IN_ARENA;
|
||||
}
|
||||
case 74410: // Arena - Dampening
|
||||
return player && player->InArena() ? SPELL_CAST_OK : SPELL_FAILED_ONLY_IN_ARENA;
|
||||
case 74411: // Battleground - Dampening
|
||||
{
|
||||
if (!player)
|
||||
return SPELL_FAILED_ONLY_BATTLEGROUNDS;
|
||||
|
||||
BattleGround* bg = player->GetBattleGround();
|
||||
return bg && !bg->isArena() ? SPELL_CAST_OK : SPELL_FAILED_ONLY_BATTLEGROUNDS;
|
||||
}
|
||||
}
|
||||
|
||||
return SPELL_CAST_OK;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue