mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 10:55:43 +00:00
refactor(Scripts/Pet): code cleanup (part 8) (#6928)
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
#include "CellImpl.h"
|
||||
#include "CombatAI.h"
|
||||
#include "GridNotifiers.h"
|
||||
#include "GridNotifiersImpl.h"
|
||||
#include "PassiveAI.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "ScriptMgr.h"
|
||||
@@ -62,10 +61,13 @@ public:
|
||||
|
||||
// Xinef: Night of the Dead avoidance
|
||||
if (Aura* aur = me->GetAura(SPELL_DK_NIGHT_OF_THE_DEAD))
|
||||
if (Unit* owner = me->GetOwner())
|
||||
if (AuraEffect* aurEff = owner->GetAuraEffect(SPELL_AURA_ADD_FLAT_MODIFIER, SPELLFAMILY_DEATHKNIGHT, 2718, 0))
|
||||
if (aur->GetEffect(0))
|
||||
aur->GetEffect(0)->SetAmount(-aurEff->GetSpellInfo()->Effects[EFFECT_2].CalcValue());
|
||||
if (AuraEffect* aurEff = owner->GetAuraEffect(SPELL_AURA_ADD_FLAT_MODIFIER, SPELLFAMILY_DEATHKNIGHT, 2718, 0))
|
||||
{
|
||||
if (aur->GetEffect(0))
|
||||
{
|
||||
aur->GetEffect(0)->SetAmount(-aurEff->GetSpellInfo()->Effects[EFFECT_2].CalcValue());
|
||||
}
|
||||
}
|
||||
|
||||
me->SetCanFly(true);
|
||||
me->SetDisableGravity(true);
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
#include "CreatureTextMgr.h"
|
||||
#include "Group.h"
|
||||
#include "PassiveAI.h"
|
||||
#include "PetAI.h"
|
||||
#include "Player.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "ScriptedGossip.h"
|
||||
|
||||
@@ -21,11 +21,6 @@ enum HunterSpells
|
||||
SPELL_HUNTER_PET_SCALING = 62915
|
||||
};
|
||||
|
||||
enum HunterCreatures
|
||||
{
|
||||
NPC_HUNTER_VIPER = 19921
|
||||
};
|
||||
|
||||
class npc_pet_hunter_snake_trap : public CreatureScript
|
||||
{
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user