aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Outland/TempestKeep
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2024-01-08 22:23:12 +0100
committerShauren <shauren.trinity@gmail.com>2024-01-08 22:23:12 +0100
commit605e5f94c0d71cad8e83fa5a07eaec4e6bed9cc3 (patch)
tree5cad677458a22ef0dd187fa86d1cd574282384dd /src/server/scripts/Outland/TempestKeep
parenteeb4407f077bf567361becdbe5083c2790f00313 (diff)
Core/Creatures: Moved autoattack handling from scripts to game
Diffstat (limited to 'src/server/scripts/Outland/TempestKeep')
-rw-r--r--src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp14
-rw-r--r--src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp4
-rw-r--r--src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp11
-rw-r--r--src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp4
-rw-r--r--src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp3
-rw-r--r--src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp1
-rw-r--r--src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp2
-rw-r--r--src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp10
19 files changed, 1 insertions, 70 deletions
diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp
index aa42fe49dfa..26e5071f66f 100644
--- a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp
@@ -442,19 +442,9 @@ struct boss_alar : public BossAI
FlamePatch_Timer -= diff;
}
- DoMeleeAttackIfReady();
- }
-
- void DoMeleeAttackIfReady()
- {
if (me->isAttackReady() && !me->IsNonMeleeSpellCast(false))
{
- if (me->IsWithinMeleeRange(me->GetVictim()))
- {
- me->AttackerStateUpdate(me->GetVictim());
- me->resetAttackTimer();
- }
- else
+ if (!me->IsWithinMeleeRange(me->GetVictim()))
{
if (Unit* target = me->SelectNearestTargetInAttackDistance(5))
AttackStart(target);
@@ -533,8 +523,6 @@ struct npc_ember_of_alar : public ScriptedAI
me->KillSelf();
//me->SetVisibility(VISIBILITY_OFF);
}
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp
index 806d379c0fc..4ae564a5b3c 100644
--- a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp
@@ -395,8 +395,6 @@ struct boss_high_astromancer_solarian : public BossAI
me->SetArmor(WV_ARMOR, 0);
me->SetDisplayId(MODEL_VOIDWALKER);
}
-
- DoMeleeAttackIfReady();
}
};
@@ -470,8 +468,6 @@ struct npc_solarium_priest : public ScriptedAI
}
else
aoesilenceTimer -= diff;
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp
index 4a9c11101c7..eb7c25db955 100644
--- a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp
@@ -745,9 +745,6 @@ struct boss_kaelthas : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING) && !me->FindCurrentSpellBySpellId(SPELL_KAEL_GAINING_POWER) && !me->FindCurrentSpellBySpellId(SPELL_KAEL_STUNNED))
return;
}
-
- if (events.IsInPhase(PHASE_COMBAT))
- DoMeleeAttackIfReady();
}
private:
uint8 _advisorCounter;
@@ -966,8 +963,6 @@ struct boss_thaladred_the_darkener : public advisorbase_ai
}
else
PsychicBlow_Timer -= diff;
-
- DoMeleeAttackIfReady();
}
};
@@ -1019,8 +1014,6 @@ struct boss_lord_sanguinar : public advisorbase_ai
}
else
Fear_Timer -= diff;
-
- DoMeleeAttackIfReady();
}
};
@@ -1202,8 +1195,6 @@ struct boss_master_engineer_telonicus : public advisorbase_ai
}
else
RemoteToy_Timer -= diff;
-
- DoMeleeAttackIfReady();
}
};
@@ -1265,8 +1256,6 @@ struct npc_phoenix_tk : public ScriptedAI
}
else
Cycle_Timer -= diff;
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp
index b15e165bbe2..75d03ce798d 100644
--- a/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp
@@ -139,8 +139,6 @@ struct boss_void_reaver : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp
index 1697cf13df2..a4af7fc1d50 100644
--- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp
@@ -108,8 +108,6 @@ struct boss_gatewatcher_gyrokill : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp
index 8d09645b02a..770ce2090e8 100644
--- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp
@@ -114,8 +114,6 @@ struct boss_gatewatcher_iron_hand : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp
index cc13773a290..1da49ecd87f 100644
--- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp
@@ -152,8 +152,6 @@ struct boss_mechano_lord_capacitus : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp
index 3ca064382e3..9d4325e080d 100644
--- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp
@@ -134,8 +134,6 @@ struct boss_nethermancer_sepethrea : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
@@ -193,8 +191,6 @@ struct npc_raging_flames : public ScriptedAI
return;
_scheduler.Update(diff);
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp
index 11dbd778ab8..779a8a411da 100644
--- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp
+++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp
@@ -151,8 +151,6 @@ struct boss_pathaleon_the_calculator : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
@@ -220,7 +218,6 @@ struct npc_nether_wraith : public ScriptedAI
else
Die_Timer -= diff;
}
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp
index 765d655a6c9..d8b433b8c3b 100644
--- a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp
+++ b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp
@@ -212,8 +212,6 @@ struct npc_millhouse_manastorm : public ScriptedAI
}
else
Fireball_Timer -=diff;
-
- DoMeleeAttackIfReady();
}
};
/*#####
diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp
index d445cd2b7e8..cc988250d5d 100644
--- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp
+++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp
@@ -178,8 +178,6 @@ struct boss_dalliah_the_doomsayer : public BossAI
soccothrates->AI()->Talk(SAY_DALLIAH_25_PERCENT);
soccothratesTaunt = true;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp
index 62aec2b0374..69d58090969 100644
--- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp
+++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp
@@ -263,7 +263,6 @@ struct boss_harbinger_skyriss : public BossAI
else
ManaBurn_Timer -=diff;
}
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp
index ab0c7473639..ba95dd2eb50 100644
--- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp
+++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp
@@ -271,8 +271,6 @@ struct boss_wrath_scryer_soccothrates : public BossAI
dalliah->AI()->Talk(SAY_SOCCOTHRATES_25_PERCENT);
dalliahTaunt = true;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp
index 9c27ae56381..07530c273af 100644
--- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp
+++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp
@@ -106,8 +106,6 @@ struct boss_zereketh_the_unbound : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp
index 896df533363..3cb7030f1bd 100644
--- a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp
+++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp
@@ -143,8 +143,6 @@ struct boss_commander_sarannis : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp
index aedc8509b6e..3fa2617f90b 100644
--- a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp
+++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp
@@ -138,8 +138,6 @@ struct boss_high_botanist_freywinn : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp
index 833df956b12..53ecf51cdfc 100644
--- a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp
+++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp
@@ -140,8 +140,6 @@ struct boss_laj : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp
index 1af1d6c10cd..ce4d2100ce5 100644
--- a/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp
+++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp
@@ -147,8 +147,6 @@ class boss_thorngrin_the_tender : public CreatureScript
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
private:
diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp
index e4672be695a..65ee3e6d241 100644
--- a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp
+++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp
@@ -137,8 +137,6 @@ struct boss_warp_splinter : public BossAI
if (me->HasUnitState(UNIT_STATE_CASTING))
return;
}
-
- DoMeleeAttackIfReady();
}
};
@@ -161,14 +159,6 @@ struct npc_warp_splinter_sapling : public ScriptedAI
me->DespawnOrUnsummon(2s);
}
}
-
- void UpdateAI(uint32 /*diff*/) override
- {
- if (!UpdateVictim())
- return;
-
- DoMeleeAttackIfReady();
- }
};
void AddSC_boss_warp_splinter()