TrinityCore
OutdoorPvPZM.h
Go to the documentation of this file.
1/*
2 * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the
6 * Free Software Foundation; either version 2 of the License, or (at your
7 * option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#ifndef OUTDOOR_PVP_ZM_
19#define OUTDOOR_PVP_ZM_
20
21#include "OutdoorPvP.h"
22
24{
25 TEXT_WEST_BEACON_TAKEN_ALLIANCE = 15541, // '|cffffff00The Alliance has taken control of the West Beacon!|r'
26 TEXT_WEST_BEACON_TAKEN_HORDE = 15543, // '|cffffff00The Horde has taken control of the West Beacon!|r'
27 TEXT_EAST_BEACON_TAKEN_ALLIANCE = 15546, // '|cffffff00The Alliance has taken control of the East Beacon!|r'
28 TEXT_EAST_BEACON_TAKEN_HORDE = 15545, // '|cffffff00The Horde has taken control of the East Beacon!|r'
29 TEXT_TWIN_SPIRE_RUINS_TAKEN_ALLIANCE = 15591, // '|cffffff00The Alliance has taken control of Twin Spire Ruins!|r'
30 TEXT_TWIN_SPIRE_RUINS_TAKEN_HORDE = 15590, // '|cffffff00The Horde has taken control of Twin Spire Ruins!|r'
31 TEXT_BOTH_BEACONS_TAKEN_ALLIANCE = 16284, // (NYI) '|cffffff00The Alliance has taken control of both beacons!|r'
32 TEXT_BOTH_BEACONS_TAKEN_HORDE = 16285, // (NYI) '|cffffff00The Horde has taken control of both beacons!|r'
33 TEXT_BATTLE_STANDARDS_ALLIANCE = 16287, // (NYI) '|cffffff00The Alliance Field Scout is now issuing battle standards.|r'
34 TEXT_BATTLE_STANDARDS_HORDE = 16288 // (NYI) '|cffffff00The Horde Field Scout is now issuing battle standards.|r'
35};
36
38{
39 // cast on the players of the controlling faction
40 ZM_CAPTURE_BUFF = 33779, // twin spire blessing
41 // spell that the field scout casts on the player to carry the flag
43 // spell that the field scout casts on the player to carry the flag
45 // token create spell
47 // token create spell
49};
50
52{
55};
56
58{
62};
63
65{
72
82
87};
88
90{
94};
95
97{
102
108
110{
115
117{
121
122class OutdoorPvPZM;
123
125{
126public:
127 ZMControlZoneHandler(OutdoorPvPZM* pvp, uint32 textBeaconTakenHorde, uint32 textBeaconTakenAlliance, uint32 worldstateNeutralUi, uint32 worldstateNeutralMap, uint32 worldstateHordeUi, uint32 worldstateHordeMap, uint32 worldstateAllianceUi, uint32 worldstateAllianceMap);
128
129 void HandleProgressEventHorde([[maybe_unused]] GameObject* controlZone) override;
130 void HandleProgressEventAlliance([[maybe_unused]] GameObject* controlZone) override;
131 void HandleNeutralEventHorde([[maybe_unused]] GameObject* controlZone) override;
132 void HandleNeutralEventAlliance([[maybe_unused]] GameObject* controlZone) override;
133 void HandleNeutralEvent([[maybe_unused]] GameObject* controlZone) override;
134
141
143
144private:
153};
154
156{
157 public:
159
160 void Update(uint32 diff) override;
161 void ChangeState() override { }
162 int32 HandleOpenGo(Player* player, GameObject* go) override;
163 bool HandleDropFlag(Player* player, uint32 spellId) override;
164
165 void UpdateTowerState();
166 void SetBeaconState(uint32 controlling_team); // not good atm
168
171
172 protected:
176};
177
180{
181 public:
182 OutdoorPvPZM(Map* map);
183
184 bool SetupOutdoorPvP() override;
185 void HandlePlayerEnterZone(Player* player, uint32 zone) override;
186 void HandlePlayerLeaveZone(Player* player, uint32 zone) override;
187 void Update(uint32 diff) override;
188 void SendRemoveWorldStates(Player* player) override;
189 void HandleKillImpl(Player* player, Unit* killed) override;
190
195
197
198 private:
202};
203
204#endif
int32_t int32
Definition: Define.h:138
uint32_t uint32
Definition: Define.h:142
DefenseMessages
Definition: OutdoorPvPHP.h:25
ZM_TowerStateMask
Definition: OutdoorPvPZM.h:90
@ ZM_TOWERSTATE_N
Definition: OutdoorPvPZM.h:91
@ ZM_TOWERSTATE_H
Definition: OutdoorPvPZM.h:93
@ ZM_TOWERSTATE_A
Definition: OutdoorPvPZM.h:92
ZM_WorldEvents
Definition: OutdoorPvPZM.h:97
@ ZM_EVENT_BEACON_WEST_NEUTRAL_ALLIANCE
Definition: OutdoorPvPZM.h:106
@ ZM_EVENT_BEACON_EAST_NEUTRAL_HORDE
Definition: OutdoorPvPZM.h:100
@ ZM_EVENT_BEACON_WEST_PROGRESS_ALLIANCE
Definition: OutdoorPvPZM.h:104
@ ZM_EVENT_BEACON_WEST_PROGRESS_HORDE
Definition: OutdoorPvPZM.h:103
@ ZM_EVENT_BEACON_EAST_PROGRESS_ALLIANCE
Definition: OutdoorPvPZM.h:99
@ ZM_EVENT_BEACON_EAST_NEUTRAL_ALLIANCE
Definition: OutdoorPvPZM.h:101
@ ZM_EVENT_BEACON_WEST_NEUTRAL_HORDE
Definition: OutdoorPvPZM.h:105
@ ZM_EVENT_BEACON_EAST_PROGRESS_HORDE
Definition: OutdoorPvPZM.h:98
ZM_GameObjectEntries
Definition: OutdoorPvPZM.h:117
@ ZM_GO_ENTRY_BEACON_WEST
Definition: OutdoorPvPZM.h:118
@ ZM_GO_ENTRY_BEACON_EAST
Definition: OutdoorPvPZM.h:119
ZM_BeaconType
Definition: OutdoorPvPZM.h:58
@ ZM_BEACON_EAST
Definition: OutdoorPvPZM.h:59
@ ZM_BEACON_WEST
Definition: OutdoorPvPZM.h:60
@ ZM_NUM_BEACONS
Definition: OutdoorPvPZM.h:61
@ TEXT_EAST_BEACON_TAKEN_ALLIANCE
Definition: OutdoorPvPZM.h:27
@ TEXT_TWIN_SPIRE_RUINS_TAKEN_ALLIANCE
Definition: OutdoorPvPZM.h:29
@ TEXT_WEST_BEACON_TAKEN_ALLIANCE
Definition: OutdoorPvPZM.h:25
@ TEXT_BOTH_BEACONS_TAKEN_HORDE
Definition: OutdoorPvPZM.h:32
@ TEXT_BOTH_BEACONS_TAKEN_ALLIANCE
Definition: OutdoorPvPZM.h:31
@ TEXT_EAST_BEACON_TAKEN_HORDE
Definition: OutdoorPvPZM.h:28
@ TEXT_BATTLE_STANDARDS_ALLIANCE
Definition: OutdoorPvPZM.h:33
@ TEXT_TWIN_SPIRE_RUINS_TAKEN_HORDE
Definition: OutdoorPvPZM.h:30
@ TEXT_WEST_BEACON_TAKEN_HORDE
Definition: OutdoorPvPZM.h:26
@ TEXT_BATTLE_STANDARDS_HORDE
Definition: OutdoorPvPZM.h:34
ZMCreatureTypes
Definition: OutdoorPvPZM.h:52
@ ZM_HORDE_FIELD_SCOUT
Definition: OutdoorPvPZM.h:54
@ ZM_ALLIANCE_FIELD_SCOUT
Definition: OutdoorPvPZM.h:53
ZM_GraveyardState
Definition: OutdoorPvPZM.h:110
@ ZM_GRAVEYARD_H
Definition: OutdoorPvPZM.h:113
@ ZM_GRAVEYARD_N
Definition: OutdoorPvPZM.h:111
@ ZM_GRAVEYARD_A
Definition: OutdoorPvPZM.h:112
OutdoorPvPZMSpells
Definition: OutdoorPvPZM.h:38
@ ZM_BATTLE_STANDARD_H
Definition: OutdoorPvPZM.h:44
@ ZM_BATTLE_STANDARD_A
Definition: OutdoorPvPZM.h:42
@ ZM_CAPTURE_BUFF
Definition: OutdoorPvPZM.h:40
@ ZM_AlliancePlayerKillReward
Definition: OutdoorPvPZM.h:46
@ ZM_HordePlayerKillReward
Definition: OutdoorPvPZM.h:48
OutdoorPvPZMWorldStates
Definition: OutdoorPvPZM.h:65
@ ZM_MAP_TOWER_EAST_A
Definition: OutdoorPvPZM.h:75
@ ZM_MAP_HORDE_FLAG_NOT_READY
Definition: OutdoorPvPZM.h:84
@ ZM_UI_TOWER_WEST_N
Definition: OutdoorPvPZM.h:69
@ ZM_UI_TOWER_WEST_A
Definition: OutdoorPvPZM.h:71
@ ZM_MAP_ALLIANCE_FLAG_READY
Definition: OutdoorPvPZM.h:86
@ ZM_MAP_GRAVEYARD_A
Definition: OutdoorPvPZM.h:77
@ ZM_MAP_TOWER_WEST_N
Definition: OutdoorPvPZM.h:79
@ ZM_MAP_TOWER_WEST_A
Definition: OutdoorPvPZM.h:81
@ ZM_MAP_GRAVEYARD_N
Definition: OutdoorPvPZM.h:78
@ ZM_MAP_GRAVEYARD_H
Definition: OutdoorPvPZM.h:76
@ ZM_UI_TOWER_EAST_H
Definition: OutdoorPvPZM.h:67
@ ZM_MAP_TOWER_EAST_N
Definition: OutdoorPvPZM.h:73
@ ZM_UI_TOWER_WEST_H
Definition: OutdoorPvPZM.h:70
@ ZM_MAP_TOWER_WEST_H
Definition: OutdoorPvPZM.h:80
@ ZM_MAP_HORDE_FLAG_READY
Definition: OutdoorPvPZM.h:83
@ ZM_MAP_ALLIANCE_FLAG_NOT_READY
Definition: OutdoorPvPZM.h:85
@ ZM_UI_TOWER_EAST_A
Definition: OutdoorPvPZM.h:68
@ ZM_UI_TOWER_EAST_N
Definition: OutdoorPvPZM.h:66
@ ZM_MAP_TOWER_EAST_H
Definition: OutdoorPvPZM.h:74
Definition: Map.h:189
void Update(uint32 diff) override
void SetFlagCarrierGUID(ObjectGuid guid)
Definition: OutdoorPvPZM.h:170
OPvPCapturePointZM_Graveyard(OutdoorPvP *pvp)
bool HandleDropFlag(Player *player, uint32 spellId) override
void SetBeaconState(uint32 controlling_team)
int32 HandleOpenGo(Player *player, GameObject *go) override
ObjectGuid GetFlagCarrierGUID() const
Definition: OutdoorPvPZM.h:169
void Update(uint32 diff) override
OPvPCapturePointZM_Graveyard * GetGraveyard()
Definition: OutdoorPvPZM.h:196
void SetHordeTowersControlled(uint32 count)
uint32 GetAllianceTowersControlled() const
void HandleKillImpl(Player *player, Unit *killed) override
bool SetupOutdoorPvP() override
void HandlePlayerEnterZone(Player *player, uint32 zone) override
void HandlePlayerLeaveZone(Player *player, uint32 zone) override
OPvPCapturePointZM_Graveyard * m_Graveyard
Definition: OutdoorPvPZM.h:199
uint32 GetHordeTowersControlled() const
void SetAllianceTowersControlled(uint32 count)
void SendRemoveWorldStates(Player *player) override
uint32 m_HordeTowersControlled
Definition: OutdoorPvPZM.h:201
OutdoorPvPZM(Map *map)
uint32 m_AllianceTowersControlled
Definition: OutdoorPvPZM.h:200
Definition: Unit.h:627
void HandleProgressEventAlliance(GameObject *controlZone) override
uint32 GetWorldStateNeutralUI()
Definition: OutdoorPvPZM.h:135
OutdoorPvPZM * GetOutdoorPvpZM()
uint32 GetWorldStateHordeMap()
Definition: OutdoorPvPZM.h:138
void HandleNeutralEventAlliance(GameObject *controlZone) override
uint32 _textBeaconTakenAlliance
Definition: OutdoorPvPZM.h:146
void HandleNeutralEvent(GameObject *controlZone) override
uint32 GetWorldStateAllianceUI()
Definition: OutdoorPvPZM.h:139
uint32 GetWorldStateAllianceMap()
Definition: OutdoorPvPZM.h:140
ZMControlZoneHandler(OutdoorPvPZM *pvp, uint32 textBeaconTakenHorde, uint32 textBeaconTakenAlliance, uint32 worldstateNeutralUi, uint32 worldstateNeutralMap, uint32 worldstateHordeUi, uint32 worldstateHordeMap, uint32 worldstateAllianceUi, uint32 worldstateAllianceMap)
uint32 GetWorldStateHordeUI()
Definition: OutdoorPvPZM.h:137
void HandleNeutralEventHorde(GameObject *controlZone) override
uint32 GetWorldStateNeutralMap()
Definition: OutdoorPvPZM.h:136
void HandleProgressEventHorde(GameObject *controlZone) override