[6863] Arena team related clean ups and adding parts of w12x's arena patch.

This commit is contained in:
hunuza 2008-11-18 11:41:55 +01:00
parent 7ea5f922ea
commit e19433fa73
6 changed files with 143 additions and 93 deletions

View file

@ -709,14 +709,21 @@ void BattleGround::AddPlayer(Player *plr)
plr->RemoveArenaSpellCooldowns();
//plr->RemoveArenaAuras();
plr->RemoveAllEnchantments(TEMP_ENCHANTMENT_SLOT);
if(team == ALLIANCE && plr->GetTeam() == ALLIANCE)
plr->CastSpell(plr,SPELL_ALLIANCE_GOLD_FLAG,true);
else if(team == HORDE && plr->GetTeam() == ALLIANCE)
plr->CastSpell(plr,SPELL_ALLIANCE_GREEN_FLAG,true);
else if(team == ALLIANCE && plr->GetTeam() == HORDE)
plr->CastSpell(plr,SPELL_HORDE_GOLD_FLAG,true);
if(team == ALLIANCE) // gold
{
if(plr->GetTeam() == HORDE)
plr->CastSpell(plr, SPELL_HORDE_GOLD_FLAG,true);
else
plr->CastSpell(plr, SPELL_ALLIANCE_GOLD_FLAG,true);
}
else
plr->CastSpell(plr,SPELL_HORDE_GREEN_FLAG,true);
{
if(plr->GetTeam() == HORDE) // green
plr->CastSpell(plr, SPELL_HORDE_GREEN_FLAG,true);
else
plr->CastSpell(plr, SPELL_ALLIANCE_GREEN_FLAG,true);
}
plr->DestroyConjuredItems(true);
if(GetStatus() == STATUS_WAIT_JOIN) // not started yet