mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-22 02:04:52 +01:00
Random minor code cleanup
This commit is contained in:
@@ -137,10 +137,7 @@ class boss_renataki : public CreatureScript
|
||||
|
||||
Aggro_Timer = 7000 + rand()%13000;
|
||||
} else Aggro_Timer -= diff;
|
||||
}
|
||||
|
||||
if (!Invisible)
|
||||
{
|
||||
if (ThousandBlades_Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_THOUSANDBLADES);
|
||||
|
||||
@@ -590,7 +590,7 @@ public:
|
||||
|
||||
bool OnQuestAccept(Player* player, Creature* creature, Quest const* quest)
|
||||
{
|
||||
if (quest->GetQuestId() == QUEST_STINKYS_ESCAPE_H || QUEST_STINKYS_ESCAPE_A)
|
||||
if (quest->GetQuestId() == QUEST_STINKYS_ESCAPE_H || quest->GetQuestId() == QUEST_STINKYS_ESCAPE_A)
|
||||
{
|
||||
if (npc_stinkyAI* pEscortAI = CAST_AI(npc_stinky::npc_stinkyAI, creature->AI()))
|
||||
{
|
||||
|
||||
@@ -160,7 +160,7 @@ class boss_baltharus_the_warborn : public CreatureScript
|
||||
DoAction(ACTION_CLONE);
|
||||
}
|
||||
|
||||
if (me->GetHealth() - damage > 0)
|
||||
if (me->GetHealth() > damage)
|
||||
instance->SetData(DATA_BALTHARUS_SHARED_HEALTH, me->GetHealth() - damage);
|
||||
}
|
||||
|
||||
@@ -246,7 +246,7 @@ class npc_baltharus_the_warborn_clone : public CreatureScript
|
||||
void DamageTaken(Unit* /*attacker*/, uint32& damage)
|
||||
{
|
||||
// Setting DATA_BALTHARUS_SHARED_HEALTH to 0 when killed would bug the boss.
|
||||
if (_instance && me->GetHealth() - damage > 0)
|
||||
if (_instance && me->GetHealth() > damage)
|
||||
_instance->SetData(DATA_BALTHARUS_SHARED_HEALTH, me->GetHealth() - damage);
|
||||
}
|
||||
|
||||
|
||||
@@ -104,7 +104,6 @@ class instance_ulduar : public InstanceMapScript
|
||||
AlgalonGUID = 0;
|
||||
KologarnChestGUID = 0;
|
||||
KologarnBridgeGUID = 0;
|
||||
KologarnChestGUID = 0;
|
||||
ThorimChestGUID = 0;
|
||||
HodirRareCacheGUID = 0;
|
||||
HodirChestGUID = 0;
|
||||
|
||||
@@ -129,7 +129,6 @@ class boss_high_astromancer_solarian : public CreatureScript
|
||||
AppearDelay = false;
|
||||
Wrath_Timer = 20000+rand()%5000;//twice in phase one
|
||||
Phase = 1;
|
||||
Wrath_Timer = 20000+rand()%5000;//twice in phase one
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_HIGHASTROMANCERSOLARIANEVENT, NOT_STARTED);
|
||||
|
||||
@@ -503,7 +503,8 @@ public:
|
||||
if (me->IsWithinDistInMap(who, 50.0f))
|
||||
{
|
||||
if (who->GetTypeId() == TYPEID_PLAYER)
|
||||
if (who->ToPlayer()->GetQuestStatus(QUEST_GETTING_THE_BLADESPIRE_TANKED || QUEST_BLADESPIRE_KEGGER) == QUEST_STATUS_INCOMPLETE)
|
||||
if (who->ToPlayer()->GetQuestStatus(QUEST_GETTING_THE_BLADESPIRE_TANKED) == QUEST_STATUS_INCOMPLETE
|
||||
|| who->ToPlayer()->GetQuestStatus(QUEST_BLADESPIRE_KEGGER) == QUEST_STATUS_INCOMPLETE)
|
||||
PlayerGUID = who->GetGUID();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user