Core&Tools: Fix multiple issues found by a static code coverage tool
This commit is contained in:
1 parent
61016dcc66
commit
12973de799
23 files changed
+93
-47
No files matched your search
+1
-1
@@ -169,7 +169,7 @@ public:
|
||||
{
|
||||
if (InstanceScript* instance = go->GetInstanceScript())
|
||||
if (instance->GetData(DATA_EGG_EVENT) != DONE)
|
||||
if (Creature* razor = Unit::GetCreature(*go, instance ? instance->GetData64(DATA_RAZORGORE_THE_UNTAMED) : 0))
|
||||
if (Creature* razor = Unit::GetCreature(*go, instance->GetData64(DATA_RAZORGORE_THE_UNTAMED)))
|
||||
{
|
||||
razor->Attack(player, true);
|
||||
player->CastSpell(razor, SPELL_MINDCONTROL);
|
||||
|
||||
@@ -473,6 +473,7 @@ public:
|
||||
{
|
||||
case SPELL_BLAZE:
|
||||
target->CastSpell(target, SPELL_BLAZE_SUMMON, true);
|
||||
break;
|
||||
case SPELL_CONFLAGRATION:
|
||||
case SPELL_FLAME_SEAR:
|
||||
HandleTouchedSpells(target, SPELL_FLAME_TOUCHED);
|
||||
|
||||
@@ -139,10 +139,12 @@ public:
|
||||
Talk(SAY_CORPORAL_4);
|
||||
uiTimer = 2500;
|
||||
uiPhase = 5;
|
||||
break;
|
||||
case 5:
|
||||
Talk(SAY_CORPORAL_5);
|
||||
uiTimer = 0;
|
||||
uiPhase = 0;
|
||||
break;
|
||||
}
|
||||
} else uiTimer -= uiDiff;
|
||||
}
|
||||
|
||||
@@ -361,13 +361,12 @@ public:
|
||||
break;
|
||||
case 15:
|
||||
Talk(SAY_WP_2);
|
||||
break;
|
||||
case 21:
|
||||
Theldanis = GetClosestCreatureWithEntry(me, NPC_THEL_DANIS, 150);
|
||||
if (Theldanis)
|
||||
Theldanis->AI()->Talk(SAY_WP_3);
|
||||
break;
|
||||
case 22:
|
||||
break;
|
||||
case 23:
|
||||
Ughost = me->SummonCreature(NPC_GHOST_UTHER, 971.86f, -1825.42f, 81.99f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
|
||||
if (Ughost)
|
||||
|
||||
@@ -608,6 +608,7 @@ public:
|
||||
if (GameObject* pMainDoor = instance->GetGameObject(uiMainDoor))
|
||||
pMainDoor->SetGoState(GO_STATE_READY);
|
||||
DoUpdateWorldState(WORLD_STATE_VH_PRISON_STATE, 100);
|
||||
// no break
|
||||
}
|
||||
default:
|
||||
SpawnPortal();
|
||||
|
||||
@@ -90,7 +90,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)OVERRIDE {}
|
||||
void EnterCombat(Unit* /*who*/) OVERRIDE {}
|
||||
|
||||
void UpdateAI(uint32 diff) OVERRIDE
|
||||
{
|
||||
@@ -119,7 +119,8 @@ public:
|
||||
case 3:
|
||||
DoCast(me, SPELL_EXPLODE_CART, true);
|
||||
phaseTimer = 2000;
|
||||
phase = 4;
|
||||
phase = 5; // @fixme: phase 4 is missing...
|
||||
break;
|
||||
case 5:
|
||||
DoCast(me, SPELL_SUMMON_WORM, true);
|
||||
if (Unit* worm = me->FindNearestCreature(26250, 3))
|
||||
|
||||
@@ -521,9 +521,9 @@ class spell_sha_flame_shock : public SpellScriptLoader
|
||||
// Lava Flows
|
||||
if (AuraEffect const* aurEff = caster->GetDummyAuraEffect(SPELLFAMILY_SHAMAN, SHAMAN_ICON_ID_SHAMAN_LAVA_FLOW, EFFECT_0))
|
||||
{
|
||||
SpellInfo const* firstRankSpellInfo = sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_R1);
|
||||
if (!aurEff->GetSpellInfo()->IsRankOf(firstRankSpellInfo))
|
||||
return;
|
||||
if (SpellInfo const* firstRankSpellInfo = sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_R1))
|
||||
if (!aurEff->GetSpellInfo()->IsRankOf(firstRankSpellInfo))
|
||||
return;
|
||||
|
||||
uint8 rank = aurEff->GetSpellInfo()->GetRank();
|
||||
caster->CastSpell(caster, sSpellMgr->GetSpellWithRank(SPELL_SHAMAN_LAVA_FLOWS_TRIGGERED_R1, rank), true);
|
||||
|
||||
Reference in new issue
Block a user