Project SkyFire Core
SkyFire 5.4.8 server core API documentation
Loading...
Searching...
No Matches
boss_baroness_anastari.cpp
Go to the documentation of this file.
1/*
2* This file is part of Project SkyFire https://www.projectskyfire.org.
3* See LICENSE.md file for Copyright information
4*/
5
6/* ScriptData
7SDName: Boss_Baroness_Anastari
8SD%Complete: 90
9SDComment: MC disabled
10SDCategory: Stratholme
11EndScriptData */
12
13#include "ScriptMgr.h"
14#include "ScriptedCreature.h"
15#include "stratholme.h"
16
18{
22 //SPELL_POSSESS = 17244
23};
24
26{
27public:
28 boss_baroness_anastari() : CreatureScript("boss_baroness_anastari") { }
29
31 {
32 return new boss_baroness_anastariAI(creature);
33 }
34
36 {
38 {
39 instance = me->GetInstanceScript();
40 }
41
43
47 //uint32 Possess_Timer;
48
50 {
51 BansheeWail_Timer = 1000;
52 BansheeCurse_Timer = 11000;
53 Silence_Timer = 13000;
54 //Possess_Timer = 35000;
55 }
56
57 void EnterCombat(Unit* /*who*/) OVERRIDE
58 {
59 }
60
61 void JustDied(Unit* /*killer*/) OVERRIDE
62 {
63 if (instance)
65 }
66
68 {
69 if (!UpdateVictim())
70 return;
71
72 //BansheeWail
73 if (BansheeWail_Timer <= diff)
74 {
75 if (rand()%100 < 95)
77 //4 seconds until we should cast this again
78 BansheeWail_Timer = 4000;
79 } else BansheeWail_Timer -= diff;
80
81 //BansheeCurse
82 if (BansheeCurse_Timer <= diff)
83 {
84 if (rand()%100 < 75)
86 //18 seconds until we should cast this again
87 BansheeCurse_Timer = 18000;
88 } else BansheeCurse_Timer -= diff;
89
90 //Silence
91 if (Silence_Timer <= diff)
92 {
93 if (rand()%100 < 80)
95 //13 seconds until we should cast this again
96 Silence_Timer = 13000;
97 } else Silence_Timer -= diff;
98
99 //Possess
100 /* if (Possess_Timer <= diff)
101 {
102 //Cast
103 if (rand()%100 < 65)
104 {
105 Unit* target = NULL;
106 target = SelectUnit(SELECT_TARGET_RANDOM, 0);
107 if (target)DoCast(target, SPELL_POSSESS);
108 }
109 //50 seconds until we should cast this again
110 Possess_Timer = 50000;
111 } else Possess_Timer -= diff;
112 */
113
115 }
116 };
117};
118
std::uint32_t uint32
Definition Define.h:77
#define OVERRIDE
Definition Define.h:60
@ IN_PROGRESS
void AddSC_boss_baroness_anastari()
bool UpdateVictim()
CreatureScript(const char *name)
void DoMeleeAttackIfReady()
Definition UnitAI.cpp:28
void DoCastVictim(uint32 spellId, bool triggered=false)
Definition UnitAI.cpp:168
Definition Unit.h:1367
CreatureAI * GetAI(Creature *creature) const OVERRIDE
@ TYPE_BARONESS
Definition stratholme.h:12
Creature * me
ScriptedAI(Creature *creature)
void UpdateAI(uint32 diff) OVERRIDE
== Triggered Actions Requested ==================