aboutsummaryrefslogtreecommitdiff
path: root/src/game/OutdoorPvPSI.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/OutdoorPvPSI.cpp')
-rw-r--r--src/game/OutdoorPvPSI.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/game/OutdoorPvPSI.cpp b/src/game/OutdoorPvPSI.cpp
index d6ddb8231e7..43e24adf555 100644
--- a/src/game/OutdoorPvPSI.cpp
+++ b/src/game/OutdoorPvPSI.cpp
@@ -69,7 +69,7 @@ bool OutdoorPvPSI::Update(uint32 diff)
void OutdoorPvPSI::HandlePlayerEnterZone(Player * plr, uint32 zone)
{
- if(plr->GetTeam() == m_LastController)
+ if (plr->GetTeam() == m_LastController)
plr->CastSpell(plr,SI_CENARION_FAVOR,true);
OutdoorPvP::HandlePlayerEnterZone(plr,zone);
}
@@ -86,12 +86,12 @@ bool OutdoorPvPSI::HandleAreaTrigger(Player *plr, uint32 trigger)
switch(trigger)
{
case SI_AREATRIGGER_A:
- if(plr->GetTeam() == ALLIANCE && plr->HasAura(SI_SILITHYST_FLAG))
+ if (plr->GetTeam() == ALLIANCE && plr->HasAura(SI_SILITHYST_FLAG))
{
// remove aura
plr->RemoveAurasDueToSpell(SI_SILITHYST_FLAG);
++ m_Gathered_A;
- if(m_Gathered_A >= SI_MAX_RESOURCES)
+ if (m_Gathered_A >= SI_MAX_RESOURCES)
{
TeamApplyBuff(TEAM_ALLIANCE, SI_CENARION_FAVOR);
sWorld.SendZoneText(OutdoorPvPSIBuffZones[0],objmgr.GetTrinityStringForDBCLocale(LANG_OPVP_SI_CAPTURE_A));
@@ -111,12 +111,12 @@ bool OutdoorPvPSI::HandleAreaTrigger(Player *plr, uint32 trigger)
}
return true;
case SI_AREATRIGGER_H:
- if(plr->GetTeam() == HORDE && plr->HasAura(SI_SILITHYST_FLAG))
+ if (plr->GetTeam() == HORDE && plr->HasAura(SI_SILITHYST_FLAG))
{
// remove aura
plr->RemoveAurasDueToSpell(SI_SILITHYST_FLAG);
++ m_Gathered_H;
- if(m_Gathered_H >= SI_MAX_RESOURCES)
+ if (m_Gathered_H >= SI_MAX_RESOURCES)
{
TeamApplyBuff(TEAM_HORDE, SI_CENARION_FAVOR);
sWorld.SendZoneText(OutdoorPvPSIBuffZones[0],objmgr.GetTrinityStringForDBCLocale(LANG_OPVP_SI_CAPTURE_H));
@@ -141,7 +141,7 @@ bool OutdoorPvPSI::HandleAreaTrigger(Player *plr, uint32 trigger)
bool OutdoorPvPSI::HandleDropFlag(Player *plr, uint32 spellId)
{
- if(spellId == SI_SILITHYST_FLAG)
+ if (spellId == SI_SILITHYST_FLAG)
{
// if it was dropped away from the player's turn-in point, then create a silithyst mound, if it was dropped near the areatrigger, then it was dispelled by the outdoorpvp, so do nothing
switch(plr->GetTeam())
@@ -149,21 +149,21 @@ bool OutdoorPvPSI::HandleDropFlag(Player *plr, uint32 spellId)
case ALLIANCE:
{
AreaTriggerEntry const* atEntry = sAreaTriggerStore.LookupEntry(SI_AREATRIGGER_A);
- if(atEntry)
+ if (atEntry)
{
// 5.0f is safe-distance
- if(plr->GetDistance(atEntry->x,atEntry->y,atEntry->z) > 5.0f + atEntry->radius)
+ if (plr->GetDistance(atEntry->x,atEntry->y,atEntry->z) > 5.0f + atEntry->radius)
{
// he dropped it further, summon mound
GameObject * go = new GameObject;
Map * map = plr->GetMap();
- if(!map)
+ if (!map)
{
delete go;
return true;
}
- if(!go->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT),SI_SILITHYST_MOUND, map, plr->GetPhaseMask(), plr->GetPositionX(),plr->GetPositionY(),plr->GetPositionZ(),plr->GetOrientation(),0,0,0,0,100,GO_STATE_READY))
+ if (!go->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT),SI_SILITHYST_MOUND, map, plr->GetPhaseMask(), plr->GetPositionX(),plr->GetPositionY(),plr->GetPositionZ(),plr->GetOrientation(),0,0,0,0,100,GO_STATE_READY))
{
delete go;
}
@@ -179,20 +179,20 @@ bool OutdoorPvPSI::HandleDropFlag(Player *plr, uint32 spellId)
case HORDE:
{
AreaTriggerEntry const* atEntry = sAreaTriggerStore.LookupEntry(SI_AREATRIGGER_H);
- if(atEntry)
+ if (atEntry)
{
// 5.0f is safe-distance
- if(plr->GetDistance(atEntry->x,atEntry->y,atEntry->z) > 5.0f + atEntry->radius)
+ if (plr->GetDistance(atEntry->x,atEntry->y,atEntry->z) > 5.0f + atEntry->radius)
{
// he dropped it further, summon mound
GameObject * go = new GameObject;
Map * map = plr->GetMap();
- if(!map)
+ if (!map)
{
delete go;
return true;
}
- if(!go->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT),SI_SILITHYST_MOUND, map, plr->GetPhaseMask() ,plr->GetPositionX(),plr->GetPositionY(),plr->GetPositionZ(),plr->GetOrientation(),0,0,0,0,100,GO_STATE_READY))
+ if (!go->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT),SI_SILITHYST_MOUND, map, plr->GetPhaseMask() ,plr->GetPositionX(),plr->GetPositionY(),plr->GetPositionZ(),plr->GetOrientation(),0,0,0,0,100,GO_STATE_READY))
{
delete go;
}
@@ -213,10 +213,10 @@ bool OutdoorPvPSI::HandleDropFlag(Player *plr, uint32 spellId)
bool OutdoorPvPSI::HandleCustomSpell(Player *plr, uint32 spellId, GameObject *go)
{
- if(!go || spellId != SI_SILITHYST_FLAG_GO_SPELL)
+ if (!go || spellId != SI_SILITHYST_FLAG_GO_SPELL)
return false;
plr->CastSpell(plr,SI_SILITHYST_FLAG,true);
- if(go->GetGOInfo()->id == SI_SILITHYST_MOUND)
+ if (go->GetGOInfo()->id == SI_SILITHYST_MOUND)
{
// despawn go
go->SetRespawnTime(0);