Cleaning unused variables

This commit is contained in:
Yehonal
2017-09-19 11:23:07 +02:00
parent 787a9238df
commit 944cfd077e
23 changed files with 25 additions and 25 deletions

View File

@@ -1080,7 +1080,7 @@ class spell_halion_clear_debuffs : public SpellScriptLoader
void HandleScriptEffect(SpellEffIndex /*effIndex*/)
{
if (Unit* target = GetHitUnit())
if (GetHitUnit())
{
GetHitUnit()->RemoveAurasDueToSpell(GetSpellInfo()->Effects[EFFECT_0].CalcValue());
GetHitUnit()->RemoveAurasDueToSpell(GetSpellInfo()->Effects[EFFECT_1].CalcValue());

View File

@@ -1810,7 +1810,7 @@ public:
events.RepeatEvent(5000);
break;
case EVENT_SPELL_STRANGULATE:
if( Unit* target = SelectEnemyCaster(false, 30.0f) )
if(SelectEnemyCaster(false, 30.0f))
{
me->CastSpell(me->GetVictim(), SPELL_STRANGULATE, false);
events.RepeatEvent(120000);

View File

@@ -1871,7 +1871,7 @@ public:
events.ScheduleEvent(2, 4500);
break;
case 3:
if (Unit* target = SelectTargetFromPlayerList(30.0f, 0, true))
if (SelectTargetFromPlayerList(30.0f, 0, true))
me->CastSpell(me->GetVictim(), 70145, false);
events.ScheduleEvent(3, 9000);
break;

View File

@@ -571,7 +571,7 @@ class boss_lady_deathwhisper : public CreatureScript
// helper for summoning wave mobs
void Summon(uint32 entry, const Position& pos)
{
if (TempSummon* summon = me->SummonCreature(entry, pos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000))
if (me->SummonCreature(entry, pos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000))
if (TempSummon* trigger = me->SummonCreature(WORLD_TRIGGER, pos, TEMPSUMMON_TIMED_DESPAWN, 2000))
{
trigger->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE);

View File

@@ -150,7 +150,7 @@ public:
if (GameObject* go = instance->GetGameObject(GO_ExitPortalGUID))
go->SetPhaseMask(1, true);
if (Creature* c = instance->GetCreature(NPC_MalygosGUID))
if (Creature* alexstrasza = c->SummonCreature(NPC_ALEXSTRASZA, 798.0f, 1268.0f, 299.0f, 2.45f ,TEMPSUMMON_TIMED_DESPAWN, 604800000))
if (c->SummonCreature(NPC_ALEXSTRASZA, 798.0f, 1268.0f, 299.0f, 2.45f ,TEMPSUMMON_TIMED_DESPAWN, 604800000))
break;
}
if (data == DONE)

View File

@@ -455,7 +455,7 @@ public:
}
case EVENT_ABEDNEUM_HEAD: // Third
{
if (Creature *abedneum = GetAbedneum())
if (GetAbedneum())
{
Player *plr = SelectTargetFromPlayerList(100.0f);
if (!plr)

View File

@@ -550,7 +550,7 @@ public:
events.ScheduleEvent(EVENT_ELEVATOR_INTERVAL_1, 6000);
break;
case EVENT_ELEVATOR_INTERVAL_1:
if( Creature* VX001 = me->SummonCreature(NPC_VX001, 2744.65f, 2569.46f, 364.40f, 3.14f, TEMPSUMMON_MANUAL_DESPAWN) )
if(me->SummonCreature(NPC_VX001, 2744.65f, 2569.46f, 364.40f, 3.14f, TEMPSUMMON_MANUAL_DESPAWN))
{
if( GameObject *elevator = me->FindNearestGameObject(GO_MIMIRON_ELEVATOR, 100.0f) )
{