AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
midsummer.cpp File Reference
#include "CreatureScript.h"
#include "GameEventMgr.h"
#include "GameObjectScript.h"
#include "GameTime.h"
#include "Player.h"
#include "PlayerScript.h"
#include "ScriptedCreature.h"
#include "Spell.h"
#include "SpellAuras.h"
#include "SpellScript.h"
#include "SpellScriptLoader.h"
#include <random>

Go to the source code of this file.

Classes

class  MidsummerPlayerScript
 
struct  npc_midsummer_bonfire
 
struct  npc_midsummer_bonfire_despawner
 
struct  npc_midsummer_torch_target
 
class  spell_fire_festival_fortitude
 
class  spell_bonfires_blessing
 
class  spell_gen_crab_disguise
 
struct  npc_midsummer_ribbon_pole_target
 
class  spell_midsummer_ribbon_pole_firework
 
class  spell_midsummer_ribbon_pole
 
class  spell_midsummer_ribbon_pole_visual
 
class  spell_midsummer_torch_quest
 
class  spell_midsummer_fling_torch
 
class  spell_midsummer_juggling_torch
 
class  spell_midsummer_torch_catch
 
class  spell_midsummer_summon_ahune_lieutenant
 

Enumerations

enum  eBonfire {
  GO_MIDSUMMER_BONFIRE_SPELL_FOCUS = 181371 ,
  GO_MIDSUMMER_BONFIRE_CAMPFIRE_SPELL_FOCUS = 181377 ,
  GO_AHUNE_BONFIRE = 188073 ,
  SPELL_MIDSUMMER_BONFIRE_BUNNIES_2 = 29114 ,
  SPELL_STAMP_OUT_BONFIRE = 45437 ,
  SPELL_STAMP_OUT_BONFIRE_ART_KIT = 46903 ,
  SPELL_TOSS_FUEL_ON_BONFIRE = 28806 ,
  SPELL_LIGHT_BONFIRE_ART_KIT = 46904 ,
  SPELL_BONFIRES_BLESSING = 45444 ,
  BONFIRE_TYPE_NONE = 0 ,
  BONFIRE_TYPE_ALLIANCE = 1 ,
  BONFIRE_TYPE_HORDE = 2 ,
  BONFIRE_TYPE_CITY = 3 ,
  BONFIRE_TYPE_AHUNE = 4 ,
  COUNT_GO_BONFIRE_ALLIANCE = 40 ,
  COUNT_GO_BONFIRE_HORDE = 38 ,
  COUNT_GO_BONFIRE_CITY = 9
}
 
enum  torchToss {
  GO_TORCH_TARGET_BRAZIER = 187708 ,
  NPC_TORCH_TOSS_TARGET_BUNNY = 25535 ,
  SPELL_TARGET_INDICATOR_RANK_1 = 43313 ,
  SPELL_TORCH_TOSS_LAND = 46054 ,
  SPELL_BRAZIERS_HIT_VISUAL = 45724 ,
  SPELL_TORCH_TOSS_SUCCESS_A = 45719 ,
  SPELL_TORCH_TOSS_SUCCESS_H = 46651 ,
  SPELL_TORCH_TOSS_TRAINING = 45716
}
 
enum  CrabDisguise {
  SPELL_CRAB_DISGUISE = 46337 ,
  SPELL_APPLY_DIGUISE = 34804 ,
  SPELL_FADE_DIGUISE = 47693
}
 
enum  RibbonPole {
  GO_RIBBON_POLE = 181605 ,
  SPELL_RIBBON_POLE_CHANNEL_VISUAL = 29172 ,
  SPELL_RIBBON_POLE_CHANNEL_VISUAL_2 = 29531 ,
  SPELL_TEST_RIBBON_POLE_CHANNEL_BLUE = 29705 ,
  SPELL_TEST_RIBBON_POLE_CHANNEL_RED = 29726 ,
  SPELL_TEST_RIBBON_POLE_CHANNEL_PINK = 29727 ,
  SPELL_RIBBON_POLE_PERIODIC_VISUAL = 45406 ,
  SPELL_RIBBON_POLE_FIRE_SPIRAL_VISUAL = 45421 ,
  SPELL_FLAME_RING = 46842 ,
  SPELL_FLAME_PATCH = 46836 ,
  SPELL_RIBBON_POLE_FIREWORK = 46847 ,
  SPELL_RIBBON_POLE_GROUND_FLOWER = 46969 ,
  SPELL_RIBBON_POLE_XP = 29175 ,
  NPC_RIBBON_POLE_DEBUG_TARGET = 17066 ,
  NPC_GROUND_FLOWER = 25518 ,
  NPC_BIG_DANCING_FLAMES = 26267 ,
  NPC_RIBBON_POLE_FIRE_SPIRAL_BUNNY = 25303 ,
  THRESHOLD_FLAME_CIRCLE = 1 ,
  THRESHOLD_FIREWORK = 2 ,
  THRESHOLD_FIREWORK_3 = 3 ,
  THRESHOLD_FIREWORK_5 = 5 ,
  THRESHOLD_GROUND_FLOWERS = 3 ,
  THRESHOLD_SPEW_LAVA = 6 ,
  THRESHOLD_DANCING_FLAMES = 7 ,
  MAX_COUNT_GROUND_FLOWERS = 3 ,
  MAX_COUNT_SPEW_LAVA_TARGETS = 2 ,
  MAX_COUNT_DANCING_FLAMES = 4
}
 
enum  flingTorch {
  NPC_TORCH_TARGET = 26188 ,
  SPELL_FLING_TORCH = 45669 ,
  SPELL_FLING_TORCH_DUMMY = 46747 ,
  SPELL_MISSED_TORCH = 45676 ,
  SPELL_TORCH_COUNTER = 45693 ,
  SPELL_TORCH_SHADOW = 46105 ,
  SPELL_TORCH_CATCH_SUCCESS_A = 46081 ,
  SPELL_TORCH_CATCH_SUCCESS_H = 46654 ,
  SPELL_JUGGLE_TORCH = 45671 ,
  QUEST_MORE_TORCH_TOSS_A = 11924 ,
  QUEST_MORE_TORCH_TOSS_H = 11925
}
 
enum  eJuggle {
  SPELL_JUGGLE_SELF = 45638 ,
  SPELL_JUGGLE_SLOW = 45792 ,
  SPELL_JUGGLE_MED = 45806 ,
  SPELL_JUGGLE_FAST = 45816 ,
  SPELL_TORCH_CHECK = 45644 ,
  SPELL_GIVE_TORCH = 45280 ,
  QUEST_TORCH_CATCHING_A = 11657 ,
  QUEST_TORCH_CATCHING_H = 11923 ,
  SPELL_TORCH_SHADOW_SELF = 46121 ,
  SPELL_TORCH_SHADOW_SLOW = 46120 ,
  SPELL_TORCH_SHADOW_MED = 46118 ,
  SPELL_TORCH_SHADOW_FAST = 46117
}
 

Functions

void AddSC_event_midsummer_scripts ()
 

Variables

static bool BonfireStampedOutState [COUNT_GO_BONFIRE_ALLIANCE+COUNT_GO_BONFIRE_HORDE]
 
const std::map< std::tuple< uint32, uint32, TeamId >, bool * > BonfireStateStore
 
uint32 const GoBonfireAlliance [COUNT_GO_BONFIRE_ALLIANCE] = { 187564, 187914, 187916, 187917, 187919, 187920, 187921, 187922, 187923, 187924, 187925, 187926, 187927, 187928, 187929, 187930, 187931, 187932, 187933, 187934, 187935, 187936, 187937, 187938, 187939, 187940, 187941, 187942, 187943, 187944, 187945, 187946, 194032, 194035, 194036, 194038, 194040, 194044, 194045, 194049 }
 
uint32 const GoBonfireHorde [COUNT_GO_BONFIRE_HORDE] = { 187559, 187947, 187948, 187949, 187950, 187951, 187952, 187953, 187954, 187955, 187956, 187957, 187958, 187959, 187960, 187961, 187962, 187963, 187964, 187965, 187966, 187967, 187968, 187969, 187970, 187971, 187972, 187973, 187974, 187975, 194033, 194034, 194037, 194039, 194042, 194043, 194046, 194048 }
 
uint32 const GoBonfireCity [COUNT_GO_BONFIRE_CITY] = { 181332, 181333, 181334, 181335, 181336, 181337, 188128, 188129, 188352 }
 

Enumeration Type Documentation

◆ CrabDisguise

Enumerator
SPELL_CRAB_DISGUISE 
SPELL_APPLY_DIGUISE 
SPELL_FADE_DIGUISE 
560{
561 SPELL_CRAB_DISGUISE = 46337,
562 SPELL_APPLY_DIGUISE = 34804,
563 SPELL_FADE_DIGUISE = 47693,
564};
@ SPELL_CRAB_DISGUISE
Definition: midsummer.cpp:561
@ SPELL_FADE_DIGUISE
Definition: midsummer.cpp:563
@ SPELL_APPLY_DIGUISE
Definition: midsummer.cpp:562

◆ eBonfire

enum eBonfire
Enumerator
GO_MIDSUMMER_BONFIRE_SPELL_FOCUS 
GO_MIDSUMMER_BONFIRE_CAMPFIRE_SPELL_FOCUS 
GO_AHUNE_BONFIRE 
SPELL_MIDSUMMER_BONFIRE_BUNNIES_2 
SPELL_STAMP_OUT_BONFIRE 
SPELL_STAMP_OUT_BONFIRE_ART_KIT 
SPELL_TOSS_FUEL_ON_BONFIRE 
SPELL_LIGHT_BONFIRE_ART_KIT 
SPELL_BONFIRES_BLESSING 
BONFIRE_TYPE_NONE 
BONFIRE_TYPE_ALLIANCE 
BONFIRE_TYPE_HORDE 
BONFIRE_TYPE_CITY 
BONFIRE_TYPE_AHUNE 
COUNT_GO_BONFIRE_ALLIANCE 
COUNT_GO_BONFIRE_HORDE 
COUNT_GO_BONFIRE_CITY 
32{
35 GO_AHUNE_BONFIRE = 188073,
36
38
41
44
46
52
56};
@ COUNT_GO_BONFIRE_HORDE
Definition: midsummer.cpp:54
@ SPELL_LIGHT_BONFIRE_ART_KIT
Definition: midsummer.cpp:43
@ SPELL_STAMP_OUT_BONFIRE
Definition: midsummer.cpp:39
@ SPELL_STAMP_OUT_BONFIRE_ART_KIT
Definition: midsummer.cpp:40
@ SPELL_MIDSUMMER_BONFIRE_BUNNIES_2
Definition: midsummer.cpp:37
@ BONFIRE_TYPE_NONE
Definition: midsummer.cpp:47
@ COUNT_GO_BONFIRE_CITY
Definition: midsummer.cpp:55
@ GO_MIDSUMMER_BONFIRE_SPELL_FOCUS
Definition: midsummer.cpp:33
@ BONFIRE_TYPE_CITY
Definition: midsummer.cpp:50
@ GO_MIDSUMMER_BONFIRE_CAMPFIRE_SPELL_FOCUS
Definition: midsummer.cpp:34
@ BONFIRE_TYPE_ALLIANCE
Definition: midsummer.cpp:48
@ COUNT_GO_BONFIRE_ALLIANCE
Definition: midsummer.cpp:53
@ SPELL_TOSS_FUEL_ON_BONFIRE
Definition: midsummer.cpp:42
@ BONFIRE_TYPE_AHUNE
Definition: midsummer.cpp:51
@ BONFIRE_TYPE_HORDE
Definition: midsummer.cpp:49
@ SPELL_BONFIRES_BLESSING
Definition: midsummer.cpp:45
@ GO_AHUNE_BONFIRE
Definition: midsummer.cpp:35

◆ eJuggle

enum eJuggle
Enumerator
SPELL_JUGGLE_SELF 
SPELL_JUGGLE_SLOW 
SPELL_JUGGLE_MED 
SPELL_JUGGLE_FAST 
SPELL_TORCH_CHECK 
SPELL_GIVE_TORCH 
QUEST_TORCH_CATCHING_A 
QUEST_TORCH_CATCHING_H 
SPELL_TORCH_SHADOW_SELF 
SPELL_TORCH_SHADOW_SLOW 
SPELL_TORCH_SHADOW_MED 
SPELL_TORCH_SHADOW_FAST 
1136{
1137 SPELL_JUGGLE_SELF = 45638,
1138 SPELL_JUGGLE_SLOW = 45792,
1139 SPELL_JUGGLE_MED = 45806,
1140 SPELL_JUGGLE_FAST = 45816,
1141
1142 SPELL_TORCH_CHECK = 45644,
1143 SPELL_GIVE_TORCH = 45280,
1144 QUEST_TORCH_CATCHING_A = 11657,
1145 QUEST_TORCH_CATCHING_H = 11923,
1146
1149 SPELL_TORCH_SHADOW_MED = 46118,
1151};
@ SPELL_TORCH_SHADOW_MED
Definition: midsummer.cpp:1149
@ QUEST_TORCH_CATCHING_A
Definition: midsummer.cpp:1144
@ SPELL_TORCH_CHECK
Definition: midsummer.cpp:1142
@ QUEST_TORCH_CATCHING_H
Definition: midsummer.cpp:1145
@ SPELL_GIVE_TORCH
Definition: midsummer.cpp:1143
@ SPELL_TORCH_SHADOW_SELF
Definition: midsummer.cpp:1147
@ SPELL_JUGGLE_FAST
Definition: midsummer.cpp:1140
@ SPELL_JUGGLE_SLOW
Definition: midsummer.cpp:1138
@ SPELL_JUGGLE_SELF
Definition: midsummer.cpp:1137
@ SPELL_TORCH_SHADOW_SLOW
Definition: midsummer.cpp:1148
@ SPELL_JUGGLE_MED
Definition: midsummer.cpp:1139
@ SPELL_TORCH_SHADOW_FAST
Definition: midsummer.cpp:1150

◆ flingTorch

enum flingTorch
Enumerator
NPC_TORCH_TARGET 
SPELL_FLING_TORCH 
SPELL_FLING_TORCH_DUMMY 
SPELL_MISSED_TORCH 
SPELL_TORCH_COUNTER 
SPELL_TORCH_SHADOW 
SPELL_TORCH_CATCH_SUCCESS_A 
SPELL_TORCH_CATCH_SUCCESS_H 
SPELL_JUGGLE_TORCH 
QUEST_MORE_TORCH_TOSS_A 
QUEST_MORE_TORCH_TOSS_H 
1013{
1014 NPC_TORCH_TARGET = 26188,
1015
1016 SPELL_FLING_TORCH = 45669,
1018 SPELL_MISSED_TORCH = 45676,
1019 SPELL_TORCH_COUNTER = 45693,
1020 SPELL_TORCH_SHADOW = 46105,
1023 SPELL_JUGGLE_TORCH = 45671,
1024
1027};
@ NPC_TORCH_TARGET
Definition: midsummer.cpp:1014
@ SPELL_TORCH_SHADOW
Definition: midsummer.cpp:1020
@ QUEST_MORE_TORCH_TOSS_H
Definition: midsummer.cpp:1026
@ SPELL_JUGGLE_TORCH
Definition: midsummer.cpp:1023
@ SPELL_TORCH_CATCH_SUCCESS_H
Definition: midsummer.cpp:1022
@ SPELL_TORCH_COUNTER
Definition: midsummer.cpp:1019
@ SPELL_TORCH_CATCH_SUCCESS_A
Definition: midsummer.cpp:1021
@ SPELL_FLING_TORCH
Definition: midsummer.cpp:1016
@ QUEST_MORE_TORCH_TOSS_A
Definition: midsummer.cpp:1025
@ SPELL_FLING_TORCH_DUMMY
Definition: midsummer.cpp:1017
@ SPELL_MISSED_TORCH
Definition: midsummer.cpp:1018

◆ RibbonPole

enum RibbonPole
Enumerator
GO_RIBBON_POLE 
SPELL_RIBBON_POLE_CHANNEL_VISUAL 
SPELL_RIBBON_POLE_CHANNEL_VISUAL_2 
SPELL_TEST_RIBBON_POLE_CHANNEL_BLUE 
SPELL_TEST_RIBBON_POLE_CHANNEL_RED 
SPELL_TEST_RIBBON_POLE_CHANNEL_PINK 
SPELL_RIBBON_POLE_PERIODIC_VISUAL 
SPELL_RIBBON_POLE_FIRE_SPIRAL_VISUAL 
SPELL_FLAME_RING 
SPELL_FLAME_PATCH 
SPELL_RIBBON_POLE_FIREWORK 
SPELL_RIBBON_POLE_GROUND_FLOWER 
SPELL_RIBBON_POLE_XP 
NPC_RIBBON_POLE_DEBUG_TARGET 
NPC_GROUND_FLOWER 
NPC_BIG_DANCING_FLAMES 
NPC_RIBBON_POLE_FIRE_SPIRAL_BUNNY 
THRESHOLD_FLAME_CIRCLE 
THRESHOLD_FIREWORK 
THRESHOLD_FIREWORK_3 
THRESHOLD_FIREWORK_5 
THRESHOLD_GROUND_FLOWERS 
THRESHOLD_SPEW_LAVA 
THRESHOLD_DANCING_FLAMES 
MAX_COUNT_GROUND_FLOWERS 
MAX_COUNT_SPEW_LAVA_TARGETS 
MAX_COUNT_DANCING_FLAMES 
601{
602 GO_RIBBON_POLE = 181605,
603
609 // player spinning/rorating around himself
611 // spew lava trails
613 // blue fire ring, duration 5s
614 SPELL_FLAME_RING = 46842,
615 // red fire ring, duration 5s
616 SPELL_FLAME_PATCH = 46836,
617 // single firework explosion
620 SPELL_RIBBON_POLE_XP = 29175,
621
623 NPC_GROUND_FLOWER = 25518,
626
627 // dancing players count
635
639};
@ MAX_COUNT_DANCING_FLAMES
Definition: midsummer.cpp:638
@ SPELL_RIBBON_POLE_FIRE_SPIRAL_VISUAL
Definition: midsummer.cpp:612
@ SPELL_TEST_RIBBON_POLE_CHANNEL_RED
Definition: midsummer.cpp:607
@ SPELL_TEST_RIBBON_POLE_CHANNEL_PINK
Definition: midsummer.cpp:608
@ NPC_BIG_DANCING_FLAMES
Definition: midsummer.cpp:624
@ THRESHOLD_FLAME_CIRCLE
Definition: midsummer.cpp:628
@ SPELL_RIBBON_POLE_XP
Definition: midsummer.cpp:620
@ MAX_COUNT_GROUND_FLOWERS
Definition: midsummer.cpp:636
@ SPELL_RIBBON_POLE_PERIODIC_VISUAL
Definition: midsummer.cpp:610
@ THRESHOLD_FIREWORK
Definition: midsummer.cpp:629
@ SPELL_TEST_RIBBON_POLE_CHANNEL_BLUE
Definition: midsummer.cpp:606
@ SPELL_RIBBON_POLE_FIREWORK
Definition: midsummer.cpp:618
@ SPELL_RIBBON_POLE_GROUND_FLOWER
Definition: midsummer.cpp:619
@ SPELL_RIBBON_POLE_CHANNEL_VISUAL_2
Definition: midsummer.cpp:605
@ THRESHOLD_FIREWORK_5
Definition: midsummer.cpp:631
@ SPELL_FLAME_RING
Definition: midsummer.cpp:614
@ NPC_RIBBON_POLE_DEBUG_TARGET
Definition: midsummer.cpp:622
@ SPELL_RIBBON_POLE_CHANNEL_VISUAL
Definition: midsummer.cpp:604
@ THRESHOLD_SPEW_LAVA
Definition: midsummer.cpp:633
@ THRESHOLD_GROUND_FLOWERS
Definition: midsummer.cpp:632
@ GO_RIBBON_POLE
Definition: midsummer.cpp:602
@ SPELL_FLAME_PATCH
Definition: midsummer.cpp:616
@ NPC_RIBBON_POLE_FIRE_SPIRAL_BUNNY
Definition: midsummer.cpp:625
@ NPC_GROUND_FLOWER
Definition: midsummer.cpp:623
@ THRESHOLD_DANCING_FLAMES
Definition: midsummer.cpp:634
@ MAX_COUNT_SPEW_LAVA_TARGETS
Definition: midsummer.cpp:637
@ THRESHOLD_FIREWORK_3
Definition: midsummer.cpp:630

◆ torchToss

enum torchToss
Enumerator
GO_TORCH_TARGET_BRAZIER 
NPC_TORCH_TOSS_TARGET_BUNNY 
SPELL_TARGET_INDICATOR_RANK_1 
SPELL_TORCH_TOSS_LAND 
SPELL_BRAZIERS_HIT_VISUAL 
SPELL_TORCH_TOSS_SUCCESS_A 
SPELL_TORCH_TOSS_SUCCESS_H 
SPELL_TORCH_TOSS_TRAINING 
392{
395
397 SPELL_TORCH_TOSS_LAND = 46054,
402};
@ GO_TORCH_TARGET_BRAZIER
Definition: midsummer.cpp:393
@ SPELL_TORCH_TOSS_LAND
Definition: midsummer.cpp:397
@ SPELL_TORCH_TOSS_TRAINING
Definition: midsummer.cpp:401
@ SPELL_BRAZIERS_HIT_VISUAL
Definition: midsummer.cpp:398
@ SPELL_TARGET_INDICATOR_RANK_1
Definition: midsummer.cpp:396
@ SPELL_TORCH_TOSS_SUCCESS_A
Definition: midsummer.cpp:399
@ SPELL_TORCH_TOSS_SUCCESS_H
Definition: midsummer.cpp:400
@ NPC_TORCH_TOSS_TARGET_BUNNY
Definition: midsummer.cpp:394

Function Documentation

◆ AddSC_event_midsummer_scripts()

void AddSC_event_midsummer_scripts ( )
1288{
1289 // Player
1291
1292 // NPCs
1297
1298 // Spells
1310}
#define RegisterCreatureAI(ai_name)
Definition: CreatureScript.h:71
#define RegisterSpellScript(spell_script)
Definition: SpellScriptLoader.h:88
Definition: midsummer.cpp:154
Definition: midsummer.cpp:182
Definition: midsummer.cpp:372
Definition: midsummer.cpp:405
Definition: midsummer.cpp:515
Definition: midsummer.cpp:536
Definition: midsummer.cpp:567
Definition: midsummer.cpp:642
Definition: midsummer.cpp:857
Definition: midsummer.cpp:873
Definition: midsummer.cpp:945
Definition: midsummer.cpp:978
Definition: midsummer.cpp:1030
Definition: midsummer.cpp:1154
Definition: midsummer.cpp:1216
Definition: midsummer.cpp:1246

References RegisterCreatureAI, and RegisterSpellScript.

Referenced by AddEventsScripts().

Variable Documentation

◆ BonfireStampedOutState

bool BonfireStampedOutState[COUNT_GO_BONFIRE_ALLIANCE+COUNT_GO_BONFIRE_HORDE]
static

◆ BonfireStateStore

const std::map<std::tuple<uint32, uint32, TeamId>, bool*> BonfireStateStore

◆ GoBonfireAlliance

uint32 const GoBonfireAlliance[COUNT_GO_BONFIRE_ALLIANCE] = { 187564, 187914, 187916, 187917, 187919, 187920, 187921, 187922, 187923, 187924, 187925, 187926, 187927, 187928, 187929, 187930, 187931, 187932, 187933, 187934, 187935, 187936, 187937, 187938, 187939, 187940, 187941, 187942, 187943, 187944, 187945, 187946, 194032, 194035, 194036, 194038, 194040, 194044, 194045, 194049 }

◆ GoBonfireCity

uint32 const GoBonfireCity[COUNT_GO_BONFIRE_CITY] = { 181332, 181333, 181334, 181335, 181336, 181337, 188128, 188129, 188352 }

◆ GoBonfireHorde

uint32 const GoBonfireHorde[COUNT_GO_BONFIRE_HORDE] = { 187559, 187947, 187948, 187949, 187950, 187951, 187952, 187953, 187954, 187955, 187956, 187957, 187958, 187959, 187960, 187961, 187962, 187963, 187964, 187965, 187966, 187967, 187968, 187969, 187970, 187971, 187972, 187973, 187974, 187975, 194033, 194034, 194037, 194039, 194042, 194043, 194046, 194048 }