Scripts/Misc: some random changes after recent commits and cleanup
This commit is contained in:
1 parent
db849e7fcc
commit
f94cfc6577
7 files changed
+31
-32
No files matched your search
@@ -48,11 +48,6 @@ class boss_maleki_the_pallid : public CreatureScript
|
||||
public:
|
||||
boss_maleki_the_pallid() : CreatureScript("boss_maleki_the_pallid") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_maleki_the_pallidAI>(creature);
|
||||
}
|
||||
|
||||
struct boss_maleki_the_pallidAI : public ScriptedAI
|
||||
{
|
||||
boss_maleki_the_pallidAI(Creature* creature) : ScriptedAI(creature)
|
||||
@@ -85,6 +80,9 @@ public:
|
||||
|
||||
_events.Update(diff);
|
||||
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
while (uint32 eventId = _events.ExecuteEvent())
|
||||
{
|
||||
switch (eventId)
|
||||
@@ -111,11 +109,16 @@ public:
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
|
||||
private:
|
||||
EventMap _events;
|
||||
InstanceScript* instance;
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_maleki_the_pallidAI>(creature);
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_boss_maleki_the_pallid()
|
||||
|
||||
@@ -55,7 +55,8 @@ enum Events
|
||||
|
||||
class boss_postmaster_malown : public CreatureScript
|
||||
{
|
||||
public: boss_postmaster_malown() : CreatureScript("boss_postmaster_malown") { }
|
||||
public:
|
||||
boss_postmaster_malown() : CreatureScript("boss_postmaster_malown") { }
|
||||
|
||||
struct boss_postmaster_malownAI : public BossAI
|
||||
{
|
||||
@@ -120,13 +121,14 @@ class boss_postmaster_malown : public CreatureScript
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new boss_postmaster_malownAI(creature);
|
||||
return GetInstanceAI<boss_postmaster_malownAI>(creature);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in new issue
Block a user