![]() |
AzerothCore 3.3.5a
OpenSource WoW Emulator
|
#include "OutdoorPvP.h"
Public Member Functions | |
OPvPCapturePoint (OutdoorPvP *pvp) | |
virtual | ~OPvPCapturePoint () |
virtual void | FillInitialWorldStates (WorldPacket &) |
void | SendUpdateWorldState (uint32 field, uint32 value) |
void | SendObjectiveComplete (uint32 id, ObjectGuid guid=ObjectGuid::Empty) |
virtual bool | HandlePlayerEnter (Player *player) |
virtual void | HandlePlayerLeave (Player *player) |
bool | IsInsideObjective (Player *player) const |
virtual bool | HandleCustomSpell (Player *player, uint32 spellId, GameObject *go) |
virtual int32 | HandleOpenGo (Player *player, GameObject *go) |
virtual bool | Update (uint32 diff) |
virtual void | ChangeState ()=0 |
virtual void | ChangeTeam (TeamId) |
virtual void | SendChangePhase () |
virtual bool | HandleGossipOption (Player *player, Creature *creature, uint32 gossipid) |
virtual bool | CanTalkTo (Player *player, Creature *c, GossipMenuItems const &gso) |
virtual bool | HandleDropFlag (Player *player, uint32 spellId) |
virtual void | DeleteSpawns () |
void | AddGO (uint32 type, ObjectGuid::LowType guid, uint32 entry=0) |
void | AddCre (uint32 type, ObjectGuid::LowType guid, uint32 entry=0) |
bool | SetCapturePointData (uint32 entry, uint32 map, float x, float y, float z, float o=0, float rotation0=0, float rotation1=0, float rotation2=0, float rotation3=0) |
void | SetSlider (float slider) |
float | GetSlider () |
Public Attributes | |
ObjectGuid::LowType | m_capturePointSpawnId |
GameObject * | m_capturePoint |
Protected Member Functions | |
bool | AddObject (uint32 type, uint32 entry, uint32 map, float x, float y, float z, float o, float rotation0, float rotation1, float rotation2, float rotation3) |
bool | AddCreature (uint32 type, uint32 entry, uint32 map, float x, float y, float z, float o, uint32 spawntimedelay=0) |
bool | DelCreature (uint32 type) |
bool | DelObject (uint32 type) |
bool | DelCapturePoint () |
Protected Attributes | |
PlayerSet | m_activePlayers [2] |
float | m_maxValue |
float | m_minValue |
float | m_maxSpeed |
float | m_value |
TeamId | m_team |
ObjectiveStates | m_OldState |
ObjectiveStates | m_State |
uint32 | m_neutralValuePct |
OutdoorPvP * | m_PvP |
std::map< uint32, ObjectGuid::LowType > | m_Objects |
std::map< uint32, ObjectGuid::LowType > | m_Creatures |
std::map< ObjectGuid::LowType, uint32 > | m_ObjectTypes |
std::map< ObjectGuid::LowType, uint32 > | m_CreatureTypes |
OPvPCapturePoint::OPvPCapturePoint | ( | OutdoorPvP * | pvp | ) |
|
inlinevirtual |
void OPvPCapturePoint::AddCre | ( | uint32 | type, |
ObjectGuid::LowType | guid, | ||
uint32 | entry = 0 |
||
) |
References CreatureData::id1, m_Creatures, m_CreatureTypes, and sObjectMgr.
Referenced by AddCreature().
|
protected |
References AddCre(), and sObjectMgr.
Referenced by OPvPCapturePointZM_GraveYard::OPvPCapturePointZM_GraveYard(), OPvPCapturePointNA::SpawnNPCsForTeam(), OPvPCapturePointEP_PWT::SummonFlightMaster(), and OPvPCapturePointEP_EWT::SummonSupportUnitAtNorthpassTower().
void OPvPCapturePoint::AddGO | ( | uint32 | type, |
ObjectGuid::LowType | guid, | ||
uint32 | entry = 0 |
||
) |
References GameObjectData::id, m_Objects, m_ObjectTypes, and sObjectMgr.
Referenced by AddObject().
|
protected |
References AddGO(), and sObjectMgr.
Referenced by OPvPCapturePointNA::HandleOpenGo(), OPvPCapturePointZM_GraveYard::HandleOpenGo(), OPvPCapturePointEP_CGT::OPvPCapturePointEP_CGT(), OPvPCapturePointEP_EWT::OPvPCapturePointEP_EWT(), OPvPCapturePointEP_NPT::OPvPCapturePointEP_NPT(), OPvPCapturePointEP_PWT::OPvPCapturePointEP_PWT(), OPvPCapturePointHP::OPvPCapturePointHP(), OPvPCapturePointZM_GraveYard::OPvPCapturePointZM_GraveYard(), OPvPCapturePointNA::SpawnGOsForTeam(), and OPvPCapturePointEP_NPT::SummonGO().
|
virtual |
Reimplemented in OPvPCapturePointZM_GraveYard.
|
pure virtual |
|
protected |
References GameObject::Delete(), m_capturePoint, m_capturePointSpawnId, GameObject::SetRespawnTime(), and sObjectMgr.
Referenced by DeleteSpawns().
|
protected |
References WorldObject::AddObjectToRemoveList(), CHAR_DEL_CREATURE_RESPAWN, CharacterDatabase, Map::GetCreatureBySpawnIdStore(), Map::GetId(), OutdoorPvP::GetMap(), LOG_DEBUG, m_Creatures, m_CreatureTypes, m_PvP, Creature::RemoveCorpse(), PreparedStatementBase::SetData(), Creature::SetRespawnTime(), and sObjectMgr.
Referenced by OPvPCapturePointEP_PWT::ChangeState(), DeleteSpawns(), OPvPCapturePointNA::DeSpawnNPCs(), OPvPCapturePointEP_PWT::SummonFlightMaster(), and OPvPCapturePointEP_EWT::SummonSupportUnitAtNorthpassTower().
|
virtual |
References DelCapturePoint(), DelCreature(), DelObject(), m_Creatures, and m_Objects.
|
protected |
References GameObject::Delete(), Map::GetGameObjectBySpawnIdStore(), OutdoorPvP::GetMap(), m_Objects, m_ObjectTypes, m_PvP, GameObject::SetRespawnTime(), and sObjectMgr.
Referenced by OPvPCapturePointEP_NPT::ChangeState(), DeleteSpawns(), OPvPCapturePointNA::DeSpawnGOs(), OPvPCapturePointNA::HandleOpenGo(), OPvPCapturePointZM_GraveYard::HandleOpenGo(), and OPvPCapturePointEP_NPT::SummonGO().
|
inlinevirtual |
|
virtual |
Reimplemented in OPvPCapturePointNA.
References Player::IsOutdoorPvPActive().
Reimplemented in OPvPCapturePointZM_GraveYard.
|
virtual |
Reimplemented in OPvPCapturePointZM_GraveYard.
|
virtual |
Reimplemented in OPvPCapturePointNA, and OPvPCapturePointZM_GraveYard.
References GameObject::GetSpawnId(), and m_ObjectTypes.
Referenced by OPvPCapturePointNA::HandleOpenGo(), and OPvPCapturePointZM_GraveYard::HandleOpenGo().
|
virtual |
Reimplemented in OPvPCapturePointEP_EWT, OPvPCapturePointEP_NPT, OPvPCapturePointEP_CGT, OPvPCapturePointEP_PWT, OPvPCapturePointGH, OPvPCapturePointHP, OPvPCapturePointNA, OPvPCapturePointTF, and OPvPCapturePointZM_Beacon.
References GameObjectTemplate::capturePoint, GameObject::GetGOInfo(), Object::GetGUID(), Player::GetTeamId(), m_activePlayers, m_capturePoint, m_maxValue, m_neutralValuePct, m_value, Player::SendUpdateWorldState(), GameObjectTemplate::worldState1, GameObjectTemplate::worldstate2, and GameObjectTemplate::worldstate3.
Referenced by OPvPCapturePointEP_EWT::HandlePlayerEnter(), OPvPCapturePointEP_NPT::HandlePlayerEnter(), OPvPCapturePointEP_CGT::HandlePlayerEnter(), OPvPCapturePointEP_PWT::HandlePlayerEnter(), OPvPCapturePointGH::HandlePlayerEnter(), OPvPCapturePointHP::HandlePlayerEnter(), OPvPCapturePointNA::HandlePlayerEnter(), OPvPCapturePointTF::HandlePlayerEnter(), OPvPCapturePointZM_Beacon::HandlePlayerEnter(), and Update().
|
virtual |
Reimplemented in OPvPCapturePointEP_EWT, OPvPCapturePointEP_NPT, OPvPCapturePointEP_CGT, OPvPCapturePointEP_PWT, OPvPCapturePointGH, OPvPCapturePointHP, OPvPCapturePointNA, OPvPCapturePointTF, and OPvPCapturePointZM_Beacon.
References GameObjectTemplate::capturePoint, GameObject::GetGOInfo(), Object::GetGUID(), Player::GetTeamId(), m_activePlayers, m_capturePoint, Player::SendUpdateWorldState(), and GameObjectTemplate::worldState1.
Referenced by OPvPCapturePointEP_EWT::HandlePlayerLeave(), OPvPCapturePointEP_NPT::HandlePlayerLeave(), OPvPCapturePointEP_CGT::HandlePlayerLeave(), OPvPCapturePointEP_PWT::HandlePlayerLeave(), OPvPCapturePointGH::HandlePlayerLeave(), OPvPCapturePointHP::HandlePlayerLeave(), OPvPCapturePointNA::HandlePlayerLeave(), OPvPCapturePointTF::HandlePlayerLeave(), OPvPCapturePointZM_Beacon::HandlePlayerLeave(), and Update().
bool OPvPCapturePoint::IsInsideObjective | ( | Player * | player | ) | const |
References Object::GetGUID(), Player::GetTeamId(), and m_activePlayers.
|
virtual |
Reimplemented in OPvPCapturePointEP_EWT, OPvPCapturePointEP_NPT, OPvPCapturePointEP_CGT, OPvPCapturePointEP_PWT, OPvPCapturePointGH, OPvPCapturePointHP, OPvPCapturePointNA, OPvPCapturePointTF, and OPvPCapturePointZM_Beacon.
References GameObjectTemplate::capturePoint, GameObject::GetGOInfo(), m_capturePoint, m_maxValue, m_neutralValuePct, m_value, SendUpdateWorldState(), GameObjectTemplate::worldState1, GameObjectTemplate::worldstate2, and GameObjectTemplate::worldstate3.
Referenced by Update().
void OPvPCapturePoint::SendObjectiveComplete | ( | uint32 | id, |
ObjectGuid | guid = ObjectGuid::Empty |
||
) |
References ObjectAccessor::FindPlayer(), m_activePlayers, m_State, OBJECTIVESTATE_ALLIANCE, and OBJECTIVESTATE_HORDE.
Referenced by OPvPCapturePointEP_EWT::ChangeState(), OPvPCapturePointEP_NPT::ChangeState(), OPvPCapturePointEP_CGT::ChangeState(), OPvPCapturePointEP_PWT::ChangeState(), and OPvPCapturePointHP::ChangeState().
References ObjectAccessor::FindPlayer(), and m_activePlayers.
Referenced by SendChangePhase(), OPvPCapturePointEP_EWT::SendChangePhase(), OPvPCapturePointEP_NPT::SendChangePhase(), OPvPCapturePointEP_CGT::SendChangePhase(), OPvPCapturePointEP_PWT::SendChangePhase(), OPvPCapturePointGH::SendChangePhase(), OPvPCapturePointHP::SendChangePhase(), OPvPCapturePointNA::SendChangePhase(), OPvPCapturePointTF::SendChangePhase(), and OPvPCapturePointZM_Beacon::SendChangePhase().
bool OPvPCapturePoint::SetCapturePointData | ( | uint32 | entry, |
uint32 | map, | ||
float | x, | ||
float | y, | ||
float | z, | ||
float | o = 0 , |
||
float | rotation0 = 0 , |
||
float | rotation1 = 0 , |
||
float | rotation2 = 0 , |
||
float | rotation3 = 0 |
||
) |
References CalculatePct(), GameObjectTemplate::capturePoint, GAMEOBJECT_TYPE_CAPTURE_POINT, LOG_DEBUG, LOG_ERROR, m_capturePointSpawnId, m_maxSpeed, m_maxValue, m_minValue, m_neutralValuePct, GameObjectTemplate::maxTime, GameObjectTemplate::minTime, GameObjectTemplate::neutralPercent, sObjectMgr, and GameObjectTemplate::type.
Referenced by OPvPCapturePointEP_CGT::OPvPCapturePointEP_CGT(), OPvPCapturePointEP_EWT::OPvPCapturePointEP_EWT(), OPvPCapturePointEP_NPT::OPvPCapturePointEP_NPT(), OPvPCapturePointEP_PWT::OPvPCapturePointEP_PWT(), OPvPCapturePointGH::OPvPCapturePointGH(), OPvPCapturePointHP::OPvPCapturePointHP(), OPvPCapturePointNA::OPvPCapturePointNA(), OPvPCapturePointTF::OPvPCapturePointTF(), and OPvPCapturePointZM_Beacon::OPvPCapturePointZM_Beacon().
|
inline |
References m_maxValue, and m_value.
|
virtual |
Reimplemented in OPvPCapturePointNA, OPvPCapturePointTF, and OPvPCapturePointZM_GraveYard.
References GameObjectTemplate::capturePoint, ChangeState(), ChangeTeam(), ObjectAccessor::FindPlayer(), GameObject::GetGOInfo(), Object::GetGUID(), Player::GetTeamId(), HandlePlayerEnter(), HandlePlayerLeave(), Player::IsOutdoorPvPActive(), GameObject::IsWithinDistInMap(), m_activePlayers, m_capturePoint, m_maxSpeed, m_maxValue, m_minValue, m_OldState, m_State, m_team, m_value, OBJECTIVESTATE_ALLIANCE, OBJECTIVESTATE_ALLIANCE_HORDE_CHALLENGE, OBJECTIVESTATE_HORDE, OBJECTIVESTATE_HORDE_ALLIANCE_CHALLENGE, OBJECTIVESTATE_NEUTRAL_ALLIANCE_CHALLENGE, OBJECTIVESTATE_NEUTRAL_HORDE_CHALLENGE, OUTDOORPVP_OBJECTIVE_UPDATE_INTERVAL, GameObjectTemplate::radius, SendChangePhase(), TEAM_ALLIANCE, TEAM_HORDE, TEAM_NEUTRAL, and Cell::VisitWorldObjects().
Referenced by OPvPCapturePointNA::Update(), and OPvPCapturePointTF::Update().
|
protected |
GameObject* OPvPCapturePoint::m_capturePoint |
Referenced by DelCapturePoint(), HandlePlayerEnter(), HandlePlayerLeave(), SendChangePhase(), and Update().
ObjectGuid::LowType OPvPCapturePoint::m_capturePointSpawnId |
Referenced by OutdoorPvP::AddCapturePoint(), OPvPCapturePointEP_EWT::ChangeState(), OPvPCapturePointEP_NPT::ChangeState(), OPvPCapturePointEP_CGT::ChangeState(), OPvPCapturePointEP_PWT::ChangeState(), OPvPCapturePointGH::ChangeState(), OPvPCapturePointHP::ChangeState(), OPvPCapturePointNA::ChangeState(), OPvPCapturePointTF::ChangeState(), DelCapturePoint(), and SetCapturePointData().
|
protected |
Referenced by AddCre(), DelCreature(), DeleteSpawns(), and OPvPCapturePointNA::GetAliveGuardsCount().
|
protected |
|
protected |
Referenced by SetCapturePointData(), and Update().
|
protected |
Referenced by HandlePlayerEnter(), OPvPCapturePointEP_EWT::HandlePlayerEnter(), OPvPCapturePointEP_NPT::HandlePlayerEnter(), OPvPCapturePointEP_CGT::HandlePlayerEnter(), OPvPCapturePointEP_PWT::HandlePlayerEnter(), OPvPCapturePointGH::HandlePlayerEnter(), OPvPCapturePointHP::HandlePlayerEnter(), OPvPCapturePointNA::HandlePlayerEnter(), OPvPCapturePointTF::HandlePlayerEnter(), OPvPCapturePointZM_Beacon::HandlePlayerEnter(), SendChangePhase(), OPvPCapturePointEP_EWT::SendChangePhase(), OPvPCapturePointEP_NPT::SendChangePhase(), OPvPCapturePointEP_CGT::SendChangePhase(), OPvPCapturePointEP_PWT::SendChangePhase(), OPvPCapturePointGH::SendChangePhase(), OPvPCapturePointHP::SendChangePhase(), OPvPCapturePointNA::SendChangePhase(), OPvPCapturePointTF::SendChangePhase(), OPvPCapturePointZM_Beacon::SendChangePhase(), SetCapturePointData(), SetSlider(), and Update().
|
protected |
Referenced by SetCapturePointData(), and Update().
|
protected |
Referenced by HandlePlayerEnter(), OPvPCapturePointEP_EWT::HandlePlayerEnter(), OPvPCapturePointEP_NPT::HandlePlayerEnter(), OPvPCapturePointEP_CGT::HandlePlayerEnter(), OPvPCapturePointEP_PWT::HandlePlayerEnter(), OPvPCapturePointGH::HandlePlayerEnter(), OPvPCapturePointHP::HandlePlayerEnter(), OPvPCapturePointNA::HandlePlayerEnter(), OPvPCapturePointTF::HandlePlayerEnter(), OPvPCapturePointZM_Beacon::HandlePlayerEnter(), SendChangePhase(), OPvPCapturePointEP_EWT::SendChangePhase(), OPvPCapturePointEP_NPT::SendChangePhase(), OPvPCapturePointEP_CGT::SendChangePhase(), OPvPCapturePointEP_PWT::SendChangePhase(), OPvPCapturePointGH::SendChangePhase(), OPvPCapturePointHP::SendChangePhase(), OPvPCapturePointNA::SendChangePhase(), OPvPCapturePointTF::SendChangePhase(), OPvPCapturePointZM_Beacon::SendChangePhase(), and SetCapturePointData().
|
protected |
|
protected |
Referenced by AddGO(), DelObject(), and HandleOpenGo().
|
protected |
Referenced by OPvPCapturePointEP_EWT::ChangeState(), OPvPCapturePointEP_NPT::ChangeState(), OPvPCapturePointEP_CGT::ChangeState(), OPvPCapturePointEP_PWT::ChangeState(), OPvPCapturePointHP::ChangeState(), OPvPCapturePointTF::ChangeState(), OPvPCapturePointZM_Beacon::ChangeState(), OPvPCapturePointTF::ResetToTeamControlled(), Update(), and OPvPCapturePointZM_GraveYard::Update().
|
protected |
Referenced by OPvPCapturePointEP_EWT::ChangeState(), OPvPCapturePointEP_NPT::ChangeState(), OPvPCapturePointEP_CGT::ChangeState(), OPvPCapturePointEP_PWT::ChangeState(), OPvPCapturePointHP::ChangeState(), OPvPCapturePointTF::ChangeState(), OPvPCapturePointZM_Beacon::ChangeState(), DelCreature(), DelObject(), OPvPCapturePointNA::FactionTakeOver(), OPvPCapturePointNA::GetAliveGuardsCount(), OPvPCapturePointZM_GraveYard::HandleOpenGo(), OPvPCapturePointNA::Update(), OPvPCapturePointTF::Update(), OPvPCapturePointNA::UpdateHalaaWorldState(), OPvPCapturePointEP_EWT::UpdateTowerState(), OPvPCapturePointEP_NPT::UpdateTowerState(), OPvPCapturePointEP_CGT::UpdateTowerState(), OPvPCapturePointEP_PWT::UpdateTowerState(), OPvPCapturePointTF::UpdateTowerState(), OPvPCapturePointZM_Beacon::UpdateTowerState(), OPvPCapturePointZM_GraveYard::UpdateTowerState(), and OPvPCapturePointNA::UpdateWyvernRoostWorldState().
|
protected |
Referenced by OPvPCapturePointEP_EWT::ChangeState(), OPvPCapturePointEP_NPT::ChangeState(), OPvPCapturePointEP_CGT::ChangeState(), OPvPCapturePointEP_PWT::ChangeState(), OPvPCapturePointGH::ChangeState(), OPvPCapturePointHP::ChangeState(), OPvPCapturePointNA::ChangeState(), OPvPCapturePointTF::ChangeState(), OPvPCapturePointZM_Beacon::ChangeState(), OPvPCapturePointHP::FillInitialWorldStates(), OPvPCapturePointTF::ResetToTeamControlled(), SendObjectiveComplete(), Update(), and OPvPCapturePointZM_GraveYard::Update().
|
protected |
Referenced by OPvPCapturePointTF::ResetToTeamControlled(), and Update().
|
protected |
Referenced by GetSlider(), HandlePlayerEnter(), OPvPCapturePointEP_EWT::HandlePlayerEnter(), OPvPCapturePointEP_NPT::HandlePlayerEnter(), OPvPCapturePointEP_CGT::HandlePlayerEnter(), OPvPCapturePointEP_PWT::HandlePlayerEnter(), OPvPCapturePointGH::HandlePlayerEnter(), OPvPCapturePointHP::HandlePlayerEnter(), OPvPCapturePointNA::HandlePlayerEnter(), OPvPCapturePointTF::HandlePlayerEnter(), OPvPCapturePointZM_Beacon::HandlePlayerEnter(), OPvPCapturePointTF::ResetToTeamControlled(), SendChangePhase(), OPvPCapturePointEP_EWT::SendChangePhase(), OPvPCapturePointEP_NPT::SendChangePhase(), OPvPCapturePointEP_CGT::SendChangePhase(), OPvPCapturePointEP_PWT::SendChangePhase(), OPvPCapturePointGH::SendChangePhase(), OPvPCapturePointHP::SendChangePhase(), OPvPCapturePointNA::SendChangePhase(), OPvPCapturePointTF::SendChangePhase(), OPvPCapturePointZM_Beacon::SendChangePhase(), SetSlider(), and Update().