TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
BattlegroundSA.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
3  * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU General Public License as published by the
7  * Free Software Foundation; either version 2 of the License, or (at your
8  * option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful, but WITHOUT
11  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13  * more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program. If not, see <http://www.gnu.org/licenses/>.
17  */
18 
19 #ifndef __BATTLEGROUNDSA_H
20 #define __BATTLEGROUNDSA_H
21 
22 #include "Battleground.h"
23 #include "BattlegroundScore.h"
24 #include "Object.h"
25 
26 #define BG_SA_FLAG_AMOUNT 3
27 #define BG_SA_DEMOLISHER_AMOUNT 4
28 
30 {
37 };
38 
40 {
44 };
45 
47 {
50 
53 
56 
59 
62 
65 
67 };
68 
70 {
77 };
78 
80 {
85 
90 };
91 
93 {
100 };
101 
103 {
107 };
108 
110 {
121 };
122 
124 {
125  // Kanrethad
128 
129  // Rigger Sparklight / Gorgril Rigspark
131 
132  // World Trigger
151 };
152 
154 {
180 };
181 
183 {
206 };
207 
209 {
214 };
215 
217 {
228  // 4 beach demolishers
233  // 4 factory demolishers
238  // Used Demolisher Salesman
241  // Kanrethad
243 };
244 
246 {
247  // Cannons
248  { 1436.429f, 110.05f, 41.407f, 5.4f },
249  { 1404.9023f, 84.758f, 41.183f, 5.46f },
250  { 1068.693f, -86.951f, 93.81f, 0.02f },
251  { 1068.83f, -127.56f, 96.45f, 0.0912f },
252  { 1422.115f, -196.433f, 42.1825f, 1.0222f },
253  { 1454.887f, -220.454f, 41.956f, 0.9627f },
254  { 1232.345f, -187.517f, 66.945f, 0.45f },
255  { 1249.634f, -224.189f, 66.72f, 0.635f },
256  { 1236.213f, 92.287f, 64.965f, 5.751f },
257  { 1215.11f, 57.772f, 64.739f, 5.78f },
258  // Demolishers
259  { 1611.597656f, -117.270073f, 8.719355f, 2.513274f},
260  { 1575.562500f, -158.421875f, 5.024450f, 2.129302f},
261  { 1618.047729f, 61.424641f, 7.248210f, 3.979351f},
262  { 1575.103149f, 98.873344f, 2.830360f, 3.752458f},
263  // Demolishers 2
264  { 1371.055786f, -317.071136f, 35.007359f, 1.947460f},
265  { 1424.034912f, -260.195190f, 31.084425f, 2.820013f},
266  { 1353.139893f, 223.745438f, 35.265411f, 4.343684f},
267  { 1404.809570f, 197.027237f, 32.046032f, 3.605401f},
268  // Npcs
269  { 1348.644165f, -298.786469f, 31.080130f, 1.710423f},
270  { 1358.191040f, 195.527786f, 31.018187f, 4.171337f},
271  { 841.921f, -134.194f, 196.838f, 6.23082f }
272 };
273 
275 {
303 };
304 
306 {
307  { 1411.57f, 108.163f, 28.692f, 5.441f },
308  { 1055.452f, -108.1f, 82.134f, 0.034f },
309  { 1431.3413f, -219.437f, 30.893f, 0.9736f },
310  { 1227.667f, -212.555f, 55.372f, 0.5023f },
311  { 1214.681f, 81.21f, 53.413f, 5.745f },
312  { 878.555f, -108.2f, 117.845f, 0.0f },
313  { 836.5f, -108.8f, 120.219f, 0.0f },
314  // Portal
315  {1468.380005f, -225.798996f, 30.896200f, 0.0f}, //blue
316  {1394.270020f, 72.551399f, 31.054300f, 0.0f}, //green
317  {1065.260010f, -89.79501f, 81.073402f, 0.0f}, //yellow
318  {1216.069946f, 47.904301f, 54.278198f, 0.0f}, //purple
319  {1255.569946f, -233.548996f, 56.43699f, 0.0f}, //red
320  // Ships
321  { 2679.696777f, -826.891235f, 3.712860f, 5.78367f}, //rot2 1 rot3 0.0002f
322  { 2574.003662f, 981.261475f, 2.603424f, 0.807696f},
323  // Sigils
324  { 1414.054f, 106.72f, 41.442f, 5.441f },
325  { 1060.63f, -107.8f, 94.7f, 0.034f },
326  { 1433.383f, -216.4f, 43.642f, 0.9736f },
327  { 1230.75f, -210.724f, 67.611f, 0.5023f },
328  { 1217.8f, 79.532f, 66.58f, 5.745f },
329  // Flagpoles
330  { 1215.114258f, -65.711861f, 70.084267f, -3.124123f},
331  {1338.863892f, -153.336533f, 30.895121f, -2.530723f},
332  {1309.124268f, 9.410645f, 30.893402f, -1.623156f},
333  // Flags
334  { 1215.108032f, -65.715767f, 70.084267f, -3.124123f},
335  { 1338.859253f, -153.327316f, 30.895077f, -2.530723f},
336  { 1309.192017f, 9.416233f, 30.893402f, 1.518436f},
337  // Bombs
338  {1333.45f, 211.354f, 31.0538f, 5.03666f},
339  {1334.29f, 209.582f, 31.0532f, 1.28088f},
340  {1332.72f, 210.049f, 31.0532f, 1.28088f},
341  {1334.28f, 210.78f, 31.0538f, 3.85856f},
342  {1332.64f, 211.39f, 31.0532f, 1.29266f},
343  {1371.41f, 194.028f, 31.5107f, 0.753095f},
344  {1372.39f, 194.951f, 31.4679f, 0.753095f},
345  {1371.58f, 196.942f, 30.9349f, 1.01777f},
346  {1370.43f, 196.614f, 30.9349f, 0.957299f},
347  {1369.46f, 196.877f, 30.9351f, 2.45348f},
348  {1370.35f, 197.361f, 30.9349f, 1.08689f},
349  {1369.47f, 197.941f, 30.9349f, 0.984787f},
350  {1592.49f, 47.5969f, 7.52271f, 4.63218f},
351  {1593.91f, 47.8036f, 7.65856f, 4.63218f},
352  {1593.13f, 46.8106f, 7.54073f, 4.63218f},
353  {1589.22f, 36.3616f, 7.45975f, 4.64396f},
354  {1588.24f, 35.5842f, 7.55613f, 4.79564f},
355  {1588.14f, 36.7611f, 7.49675f, 4.79564f},
356  {1595.74f, 35.5278f, 7.46602f, 4.90246f},
357  {1596, 36.6475f, 7.47991f, 4.90246f},
358  {1597.03f, 36.2356f, 7.48631f, 4.90246f},
359  {1597.93f, 37.1214f, 7.51725f, 4.90246f},
360  {1598.16f, 35.888f, 7.50018f, 4.90246f},
361  {1579.6f, -98.0917f, 8.48478f, 1.37996f},
362  {1581.2f, -98.401f, 8.47483f, 1.37996f},
363  {1580.38f, -98.9556f, 8.4772f, 1.38781f},
364  {1585.68f, -104.966f, 8.88551f, 0.493246f},
365  {1586.15f, -106.033f, 9.10616f, 0.493246f},
366  {1584.88f, -105.394f, 8.82985f, 0.493246f},
367  {1581.87f, -100.899f, 8.46164f, 0.929142f},
368  {1581.48f, -99.4657f, 8.46926f, 0.929142f},
369  {1583.2f, -91.2291f, 8.49227f, 1.40038f},
370  {1581.94f, -91.0119f, 8.49977f, 1.40038f},
371  {1582.33f, -91.951f, 8.49353f, 1.1844f},
372  {1342.06f, -304.049f, 30.9532f, 5.59507f},
373  {1340.96f, -304.536f, 30.9458f, 1.28323f},
374  {1341.22f, -303.316f, 30.9413f, 0.486051f},
375  {1342.22f, -302.939f, 30.986f, 4.87643f},
376  {1382.16f, -287.466f, 32.3063f, 4.80968f},
377  {1381, -287.58f, 32.2805f, 4.80968f},
378  {1381.55f, -286.536f, 32.3929f, 2.84225f},
379  {1382.75f, -286.354f, 32.4099f, 1.00442f},
380  {1379.92f, -287.34f, 32.2872f, 3.81615f},
381  {1100.52f, -2.41391f, 70.2984f, 0.131054f},
382  {1099.35f, -2.13851f, 70.3375f, 4.4586f},
383  {1099.59f, -1.00329f, 70.238f, 2.49903f},
384  {1097.79f, 0.571316f, 70.159f, 4.00307f},
385  {1098.74f, -7.23252f, 70.7972f, 4.1523f},
386  {1098.46f, -5.91443f, 70.6715f, 4.1523f},
387  {1097.53f, -7.39704f, 70.7959f, 4.1523f},
388  {1097.32f, -6.64233f, 70.7424f, 4.1523f},
389  {1096.45f, -5.96664f, 70.7242f, 4.1523f},
390  {971.725f, 0.496763f, 86.8467f, 2.09233f},
391  {973.589f, 0.119518f, 86.7985f, 3.17225f},
392  {972.524f, 1.25333f, 86.8351f, 5.28497f},
393  {971.993f, 2.05668f, 86.8584f, 5.28497f},
394  {973.635f, 2.11805f, 86.8197f, 2.36722f},
395  {974.791f, 1.74679f, 86.7942f, 1.5936f},
396  {974.771f, 3.0445f, 86.8125f, 0.647199f},
397  {979.554f, 3.6037f, 86.7923f, 1.69178f},
398  {979.758f, 2.57519f, 86.7748f, 1.76639f},
399  {980.769f, 3.48904f, 86.7939f, 1.76639f},
400  {979.122f, 2.87109f, 86.7794f, 1.76639f},
401  {986.167f, 4.85363f, 86.8439f, 1.5779f},
402  {986.176f, 3.50367f, 86.8217f, 1.5779f},
403  {987.33f, 4.67389f, 86.8486f, 1.5779f},
404  {985.23f, 4.65898f, 86.8368f, 1.5779f},
405  {984.556f, 3.54097f, 86.8137f, 1.5779f},
406 };
407 
408 /* Ships:
409  * 193182 - ally
410  * 193183 - horde
411  * 193184 - horde
412  * 193185 - ally
413  * Banners:
414  * 191308 - left one,
415  * 191306 - right one,
416  * 191310 - central,
417  * Ally ones, substract 1
418  * to get horde ones.
419  */
420 
422 {
423  190722,
424  190727,
425  190724,
426  190726,
427  190723,
428  192549,
429  192834,
430  192819,
431  192819,
432  192819,
433  192819,
434  192819,
435  0, // Boat
436  0, // Boat
437  192687,
438  192685,
439  192689,
440  192690,
441  192691,
442  191311,
443  191311,
444  191311,
445  191310,
446  191306,
447  191308,
448  190753
449 };
450 
452 {
453  1732,
454  1735,
455 };
456 
458 {
465 };
466 
468 {
469  1350,
470  1349,
471  1347,
472  1346,
473  1348,
474 };
475 
477 {
478  6.202f,
479  1.926f, // right capturable GY
480  3.917f, // left capturable GY
481  3.104f, // center, capturable
482  6.148f, // defender last GY
483 };
484 
485 struct GateInfo
486 {
492 };
493 
494 #define MAX_GATES 6
496 {
503 };
504 
506 {
509 };
510 
512 {
513  friend class BattlegroundSA;
514 
515  protected:
517 
518  void UpdateScore(uint32 type, uint32 value) override
519  {
520  switch (type)
521  {
524  break;
527  break;
528  default:
529  BattlegroundScore::UpdateScore(type, value);
530  break;
531  }
532  }
533 
534  void BuildObjectivesBlock(std::vector<int32>& stats) override
535  {
536  stats.push_back(DemolishersDestroyed);
537  stats.push_back(GatesDestroyed);
538  }
539 
540  uint32 GetAttr1() const final override { return DemolishersDestroyed; }
541  uint32 GetAttr2() const final override { return GatesDestroyed; }
542 
545 };
546 
549 {
550  public:
551  BattlegroundSA();
552  ~BattlegroundSA();
553 
559  void PostUpdateImpl(uint32 diff) override;
560 
561  /* inherited from BattlegroundClass */
563  void AddPlayer(Player* player) override;
565  void StartingEventCloseDoors() override;
566  void StartingEventOpenDoors() override;
568  bool SetupBattleground() override;
569  void Reset() override;
573  void HandleKillUnit(Creature* creature, Player* killer) override;
575  WorldSafeLocsEntry const* GetClosestGraveYard(Player* player) override;
577  void ProcessEvent(WorldObject* /*obj*/, uint32 /*eventId*/, WorldObject* /*invoker*/ = NULL) override;
579  void EventPlayerClickedOnFlag(Player* source, GameObject* go) override;
581  void TitanRelicActivated(Player* clicker);
582 
584  GateInfo const* GetGate(uint32 entry)
585  {
586  for (uint8 i = 0; i < MAX_GATES; ++i)
587  if (Gates[i].GameObjectId == entry)
588  return &Gates[i];
589  return NULL;
590  }
591 
593  void EndBattleground(uint32 winner) override;
594 
596  void RemovePlayer(Player* player, ObjectGuid guid, uint32 team) override;
597  void HandleAreaTrigger(Player* source, uint32 trigger, bool entered) override;
598 
599  /* Scorekeeping */
600 
601  // Achievement: Not Even a Scratch
602  bool CheckAchievementCriteriaMeet(uint32 criteriaId, Player const* source, Unit const* target = NULL, uint32 miscValue = 0) override;
603 
604  // Control Phase Shift
605  bool IsSpellAllowed(uint32 spellId, Player const* player) const override;
606 
607  private:
608 
614  bool ResetObjs();
616  void StartShips();
621  void TeleportPlayers();
622  void TeleportToEntrancePosition(Player* player);
627  void OverrideGunFaction();
629  void DemolisherStartState(bool start);
631  bool CanInteractWithObject(uint32 objectId);
633  void UpdateObjectInteractionFlags(uint32 objectId);
641  void DestroyGate(Player* player, GameObject* go) override;
643  void SendTime();
653  void CaptureGraveyard(BG_SA_Graveyards i, Player* Source);
655  void ToggleTimer();
656 
658  void UpdateDemolisherSpawns();
659 
661  void SendTransportInit(Player* player);
663  void SendTransportsRemove(Player* player);
664 
667 
692  std::map<uint32/*id*/, uint32/*timer*/> DemoliserRespawnList;
693 
694  // Achievement: Defense of the Ancients
696 
697  // Achievement: Not Even a Scratch
699 };
700 #endif
void HandleKillUnit(Creature *creature, Player *killer) override
Called when a player kill a unit in bg.
Definition: BattlegroundSA.cpp:635
Definition: BattlegroundSA.h:184
Definition: BattlegroundSA.h:198
Definition: BattlegroundSA.h:76
bool CheckAchievementCriteriaMeet(uint32 criteriaId, Player const *source, Unit const *target=NULL, uint32 miscValue=0) override
Definition: BattlegroundSA.cpp:1037
void StartingEventCloseDoors() override
Called when battle start.
Definition: BattlegroundSA.cpp:434
Definition: BattlegroundSA.h:291
Definition: BattlegroundSA.h:120
Definition: BattlegroundSA.h:106
bool TimerEnabled
used for know we are in timer phase or not (used for worldstate update)
Definition: BattlegroundSA.h:683
GateInfo const * GetGate(uint32 entry)
Return GateInfo, relative to bg data, according to gameobject entry.
Definition: BattlegroundSA.h:584
Definition: BattlegroundSA.h:286
Definition: BattlegroundSA.h:89
Definition: BattlegroundSA.h:164
Definition: BattlegroundSA.h:148
Definition: BattlegroundSA.h:277
BattlegroundSA()
Definition: BattlegroundSA.cpp:27
BG_SA_EventIds
Definition: BattlegroundSA.h:46
SAWorldStates
Definition: BattlegroundSA.h:153
Definition: BattlegroundSA.h:41
void PostUpdateImpl(uint32 diff) override
Called every time for update battle data -Update timer -Round switch.
Definition: BattlegroundSA.cpp:313
bool ShipsStarted
For know if boats has start moving or not yet.
Definition: BattlegroundSA.h:673
Definition: BattlegroundSA.h:280
Definition: BattlegroundSA.h:60
void HandleAreaTrigger(Player *source, uint32 trigger, bool entered) override
Definition: BattlegroundSA.cpp:490
void Reset() override
Definition: BattlegroundSA.cpp:66
Definition: BattlegroundSA.h:210
Definition: BattlegroundSA.h:52
Definition: BattlegroundSA.h:185
Definition: BattlegroundSA.h:298
Definition: BattlegroundSA.h:191
Definition: BattlegroundScore.h:51
Definition: BattlegroundSA.h:139
SASounds
Definition: BattlegroundSA.h:109
BattlegroundSAScore(ObjectGuid playerGuid, uint32 team)
Definition: BattlegroundSA.h:516
#define MAX_GATES
Definition: BattlegroundSA.h:494
uint32 const BG_SA_Factions[2]
Definition: BattlegroundSA.h:451
void DestroyGate(Player *player, GameObject *go) override
Called when a gate is destroy -Give honor to player witch destroy it -Update worldstate -Delete gameo...
Definition: BattlegroundSA.cpp:684
Definition: BattlegroundSA.h:282
uint32 GetAttr2() const finaloverride
Definition: BattlegroundSA.h:541
bool ResetObjs()
Called on setup and between the two round -Delete all gameobject / creature -Respawn all gameobject /...
Definition: BattlegroundSA.cpp:84
BG_SA_RoundScore RoundScores[2]
Score of each round.
Definition: BattlegroundSA.h:681
Definition: BattlegroundSA.h:288
Definition: BattlegroundSA.h:302
bool SetupBattleground() override
Called for ini battleground, after that the first player be entered.
Definition: BattlegroundSA.cpp:79
Definition: BattlegroundSA.h:156
Definition: BattlegroundSA.h:505
void StartShips()
Called for start ship movement.
Definition: BattlegroundSA.cpp:288
Definition: BattlegroundSA.h:300
Definition: BattlegroundSA.h:169
Definition: BattlegroundSA.h:187
Definition: BattlegroundSA.h:179
void FillInitialWorldStates(WorldPackets::WorldState::InitWorldStates &packet) override
Called for generate packet contain worldstate data.
Definition: BattlegroundSA.cpp:438
Definition: BattlegroundSA.h:54
Definition: BattlegroundSA.h:116
Definition: BattlegroundSA.h:147
Definition: BattlegroundSA.h:278
void StartingEventOpenDoors() override
Definition: BattlegroundSA.cpp:436
Definition: BattlegroundSA.h:73
Definition: BattlegroundSA.h:171
Definition: BattlegroundSA.h:176
virtual void UpdateScore(uint32 type, uint32 value)
Definition: BattlegroundScore.h:65
Definition: BattlegroundSA.h:118
Definition: BattlegroundSA.h:57
Definition: BattlegroundSA.h:293
void SendTransportsRemove(Player *player)
Send packet to player for destroy boats (client part)
Definition: BattlegroundSA.cpp:1022
Definition: BattlegroundSA.h:158
Definition: BattlegroundSA.h:157
Definition: BattlegroundSA.h:281
Definition: BattlegroundSA.h:127
Definition: BattlegroundSA.h:211
Definition: BattlegroundSA.h:43
Definition: BattlegroundSA.h:135
Definition: BattlegroundSA.h:287
Definition: DBCStructure.h:1434
Definition: BattlegroundSA.h:99
Definition: BattlegroundSA.h:142
arena_t NULL
Definition: jemalloc_internal.h:624
Definition: BattlegroundSA.h:32
uint32 const BG_SA_ObjEntries[BG_SA_MAXOBJ+BG_SA_FLAG_AMOUNT]
Definition: BattlegroundSA.h:421
BG_SA_Graveyards
Definition: BattlegroundSA.h:457
void UpdateObjectInteractionFlags()
Definition: BattlegroundSA.cpp:767
Definition: BattlegroundSA.h:289
BG_SA_Status Status
Statu of battle (Start or not, and what round)
Definition: BattlegroundSA.h:677
Definition: BattlegroundSA.h:49
Definition: BattlegroundSA.h:203
void SendTime()
Update timer worldstate.
Definition: BattlegroundSA.cpp:723
Definition: Object.h:423
Definition: Creature.h:467
GateInfo const Gates[MAX_GATES]
Definition: BattlegroundSA.h:495
Definition: BattlegroundSA.h:195
Definition: BattlegroundSA.h:98
Definition: BattlegroundSA.h:192
Definition: BattlegroundSA.h:58
Definition: BattlegroundSA.h:190
Definition: BattlegroundSA.h:212
uint32 UpdateWaitTimer
5secs before starting the 1min countdown for second round
Definition: BattlegroundSA.h:685
Definition: BattlegroundSA.h:84
Definition: BattlegroundSA.h:133
Definition: BattlegroundSA.h:201
Definition: BattlegroundSA.h:459
BG_SA_Timers
Definition: BattlegroundSA.h:102
Definition: BattlegroundSA.h:205
Definition: BattlegroundSA.h:130
Definition: BattlegroundScore.h:50
Definition: BattlegroundSA.h:87
Definition: BattlegroundSA.h:301
SASpellIds
Definition: BattlegroundSA.h:69
Definition: BattlegroundSA.h:150
uint8 DamagedText
Definition: BattlegroundSA.h:490
Definition: BattlegroundSA.h:189
void TeleportToEntrancePosition(Player *player)
Definition: BattlegroundSA.cpp:523
Definition: BattlegroundSA.h:285
uint32 EndRoundTimer
Max time of round.
Definition: BattlegroundSA.h:671
#define BG_TEAMS_COUNT
Definition: SharedDefines.h:4555
Definition: BattlegroundSA.h:105
uint32 TotalTime
Totale elapsed time of current round.
Definition: BattlegroundSA.h:669
WorldSafeLocsEntry const * GetClosestGraveYard(Player *player) override
Return the nearest graveyard where player can respawn.
Definition: BattlegroundSA.cpp:688
Definition: BattlegroundScore.h:54
std::map< uint32, uint32 > DemoliserRespawnList
Definition: BattlegroundSA.h:692
BG_SA_NPCs
Definition: BattlegroundSA.h:182
Definition: BattlegroundSA.h:75
Definition: BattlegroundSA.h:82
Definition: BattlegroundSA.h:172
Definition: BattlegroundSA.h:294
const uint32 BG_SA_GYEntries[BG_SA_MAX_GY]
Definition: BattlegroundSA.h:467
Definition: BattlegroundSA.h:170
Definition: BattlegroundSA.h:177
Definition: BattlegroundSA.h:95
Definition: BattlegroundSA.h:111
Definition: BattlegroundSA.h:166
Definition: BattlegroundSA.h:113
Definition: BattlegroundSA.h:88
Definition: BattlegroundSA.h:63
BG_SA_GateState
Definition: BattlegroundSA.h:39
Definition: BattlegroundSA.h:295
Definition: BattlegroundSA.h:81
Definition: BattlegroundSA.h:159
Definition: BattlegroundSA.h:284
Definition: BattlegroundSA.h:464
Definition: BattlegroundSA.h:71
Definition: BattlegroundSA.h:74
Definition: BattlegroundSA.h:64
BG_SA_Status
Definition: BattlegroundSA.h:29
Definition: BattlegroundSA.h:202
void RemovePlayer(Player *player, ObjectGuid guid, uint32 team) override
Called when a player leave battleground.
Definition: BattlegroundSA.cpp:488
Definition: BattlegroundSA.h:86
Definition: BattlegroundSA.h:178
void UpdateDemolisherSpawns()
Respawn dead demolisher.
Definition: BattlegroundSA.cpp:975
Definition: BattlegroundSA.h:175
Definition: BattlegroundSA.h:141
Definition: BattlegroundSA.h:83
void DemolisherStartState(bool start)
Set selectable or not demolisher, called on battle start, when boats arrive to dock.
Definition: BattlegroundSA.cpp:666
SAGameObjectIds
Definition: BattlegroundSA.h:92
void EventPlayerClickedOnFlag(Player *source, GameObject *go) override
Called when a player click on flag (graveyard flag)
Definition: BattlegroundSA.cpp:774
uint32_t uint32
Definition: Define.h:150
#define BG_SA_FLAG_AMOUNT
Definition: BattlegroundSA.h:26
Position const BG_SA_NpcSpawnlocs[BG_SA_MAXNPC]
Definition: BattlegroundSA.h:245
Definition: BattlegroundSA.h:173
bool SignaledRoundTwo
for know if warning about second round start has been sent
Definition: BattlegroundSA.h:687
Definition: BattlegroundSA.h:213
Definition: WorldStatePackets.h:27
Definition: BattlegroundSA.h:461
Definition: BattlegroundSA.h:31
Definition: GameObject.h:880
bool _allVehiclesAlive[BG_TEAMS_COUNT]
Definition: BattlegroundSA.h:698
void SendTransportInit(Player *player)
Send packet to player for create boats (client part)
Definition: BattlegroundSA.cpp:1005
bool SignaledRoundTwoHalfMin
for know if warning about second round start has been sent
Definition: BattlegroundSA.h:689
BG_SA_Objects
Definition: BattlegroundSA.h:274
uint32 GameObjectId
Definition: BattlegroundSA.h:488
Definition: BattlegroundSA.h:97
Definition: BattlegroundSA.h:193
Definition: BattlegroundSA.h:126
Definition: BattlegroundSA.h:143
void UpdateScore(uint32 type, uint32 value) override
Definition: BattlegroundSA.h:518
Definition: BattlegroundSA.h:292
TeamId
Definition: SharedDefines.h:990
BG_SA_GateState GateStatus[MAX_GATES]
Status of each gate (Destroy/Damage/Intact)
Definition: BattlegroundSA.h:675
TeamId Attackers
Id of attacker team.
Definition: BattlegroundSA.h:666
Definition: BattlegroundSA.h:94
Definition: BattlegroundSA.h:48
Definition: BattlegroundSA.h:279
TeamId GraveyardStatus[BG_SA_MAX_GY]
Team witch conntrol each graveyard.
Definition: BattlegroundSA.h:679
Definition: BattlegroundSA.h:199
Definition: BattlegroundSA.h:34
Definition: BattlegroundSA.h:463
Definition: BattlegroundSA.h:188
void BuildObjectivesBlock(std::vector< int32 > &stats) override
Definition: BattlegroundSA.h:534
Definition: BattlegroundSA.h:299
BG_SA_Boat
Definition: BattlegroundSA.h:208
Definition: BattlegroundSA.h:149
Definition: BattlegroundSA.h:460
Definition: BattlegroundSA.h:115
Definition: BattlegroundSA.h:137
Definition: BattlegroundSA.h:66
float const BG_SA_GYOrientation[BG_SA_MAX_GY]
Definition: BattlegroundSA.h:476
bool InitSecondRound
for know if second round has been init
Definition: BattlegroundSA.h:691
Definition: BattlegroundSA.h:33
bool IsSpellAllowed(uint32 spellId, Player const *player) const override
Definition: BattlegroundSA.cpp:1050
Definition: BattlegroundSA.h:290
TeamId winner
Definition: BattlegroundSA.h:507
Definition: BattlegroundSA.h:138
bool _gateDestroyed
Definition: BattlegroundSA.h:695
void TitanRelicActivated(Player *clicker)
Called when a player clicked on relic.
Definition: BattlegroundSA.cpp:887
void OverrideGunFaction()
Called on start and between the two round -Update faction of all vehicle.
Definition: BattlegroundSA.cpp:648
Definition: BattlegroundSA.h:186
uint32 const BG_SA_NpcEntries[BG_SA_MAXNPC]
Definition: BattlegroundSA.h:216
Definition: BattlegroundSA.h:462
Definition: BattlegroundSA.h:136
Definition: BattlegroundSA.h:511
Definition: BattlegroundSA.h:35
Definition: BattlegroundSA.h:204
SATexts
Definition: BattlegroundSA.h:123
Definition: BattlegroundSA.h:104
Definition: Common.h:103
void ProcessEvent(WorldObject *, uint32, WorldObject *=NULL) override
Called when someone activates an event.
Definition: BattlegroundSA.cpp:543
Definition: BattlegroundSA.h:96
Definition: BattlegroundSA.h:168
Definition: BattlegroundSA.h:112
Definition: BattlegroundSA.h:194
uint8 GateId
Definition: BattlegroundSA.h:487
Definition: BattlegroundSA.h:485
void EndBattleground(uint32 winner) override
Called on battleground ending.
Definition: BattlegroundSA.cpp:960
uint8_t uint8
Definition: Define.h:152
Definition: Position.h:27
bool CanInteractWithObject(uint32 objectId)
Checks if a player can interact with the given object.
Definition: BattlegroundSA.cpp:731
Definition: BattlegroundSA.h:160
void TeleportPlayers()
Called between the two round -Teleport all players to good location.
Definition: BattlegroundSA.cpp:497
void CaptureGraveyard(BG_SA_Graveyards i, Player *Source)
Called when a graveyard is capture -Update spiritguide -Update gameobject (flag) -Update Worldstate -...
Definition: BattlegroundSA.cpp:798
Definition: BattlegroundSA.h:296
uint32 time
Definition: BattlegroundSA.h:508
Definition: Battleground.h:235
Definition: BattlegroundSA.h:117
Definition: BattlegroundSA.h:163
Definition: BattlegroundSA.h:140
const FieldDescriptor value
Definition: descriptor.h:1522
uint32 GatesDestroyed
Definition: BattlegroundSA.h:544
void AddPlayer(Player *player) override
Called when a player join battle.
Definition: BattlegroundSA.cpp:478
Definition: BattlegroundSA.h:55
Definition: ObjectGuid.h:189
Definition: BattlegroundSA.h:134
Definition: BattlegroundSA.h:61
#define const
Definition: zconf.h:217
Definition: BattlegroundSA.h:144
Definition: BattlegroundSA.h:165
Definition: BattlegroundSA.h:200
Definition: BattlegroundSA.h:174
void ToggleTimer()
Switch on/off timer worldstate.
Definition: BattlegroundSA.cpp:954
Definition: BattlegroundSA.h:114
Definition: BattlegroundSA.h:72
Definition: Unit.h:1305
Definition: BattlegroundSA.h:36
Definition: BattlegroundSA.h:162
uint8 DestroyedText
Definition: BattlegroundSA.h:491
Definition: BattlegroundSA.h:276
Definition: BattlegroundSA.h:145
Definition: BattlegroundSA.h:119
Definition: BattlegroundSA.h:155
uint32 WorldState
Definition: BattlegroundSA.h:489
Class for manage Strand of Ancient battleground.
Definition: BattlegroundSA.h:548
Definition: BattlegroundSA.h:167
~BattlegroundSA()
Definition: BattlegroundSA.cpp:64
Definition: BattlegroundSA.h:161
Definition: BattlegroundSA.h:283
uint32 DemolishersDestroyed
Definition: BattlegroundSA.h:543
Position const BG_SA_ObjSpawnlocs[BG_SA_MAXOBJ]
Definition: BattlegroundSA.h:305
SACreatureIds
Definition: BattlegroundSA.h:79
uint32 GetAttr1() const finaloverride
Definition: BattlegroundSA.h:540
Definition: BattlegroundSA.h:297
Definition: BattlegroundSA.h:51
Definition: BattlegroundSA.h:197
Definition: BattlegroundSA.h:146
Definition: BattlegroundSA.h:42
Definition: BattlegroundSA.h:196