diff options
Diffstat (limited to 'src/server/game/Spells/SpellEffects.cpp')
-rwxr-xr-x | src/server/game/Spells/SpellEffects.cpp | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index db48f2b8693..a4cf8e6a469 100755 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -923,7 +923,7 @@ void Spell::EffectDummy(SpellEffIndex effIndex) if (m_caster->GetTypeId() != TYPEID_PLAYER) return; - uint32 spell_id = roll_chance_i(50) + spell_id = roll_chance_i(50) ? 29277 // Summon Purified Helboar Meat : 29278; // Summon Toxic Helboar Meat @@ -951,12 +951,16 @@ void Spell::EffectDummy(SpellEffIndex effIndex) return; case 35745: // Socrethar's Stone { - uint32 spell_id; switch (m_caster->GetAreaId()) { - case 3900: spell_id = 35743; break; // Socrethar Portal - case 3742: spell_id = 35744; break; // Socrethar Portal - default: return; + case 3900: + spell_id = 35743; + break; // Socrethar Portal + case 3742: + spell_id = 35744; + break; // Socrethar Portal + default: + return; } m_caster->CastSpell(m_caster, spell_id, true); @@ -1453,7 +1457,7 @@ void Spell::EffectDummy(SpellEffIndex effIndex) if (m_spellInfo->SpellFamilyFlags[0] & SPELLFAMILYFLAG_DK_DEATH_STRIKE) { uint32 count = unitTarget->GetDiseasesByCaster(m_caster->GetGUID()); - int32 bp = int32(count * m_caster->CountPctFromMaxHealth(int32(m_spellInfo->Effects[EFFECT_0].DamageMultiplier))); + bp = int32(count * m_caster->CountPctFromMaxHealth(int32(m_spellInfo->Effects[EFFECT_0].DamageMultiplier))); // Improved Death Strike if (AuraEffect const* aurEff = m_caster->GetAuraEffect(SPELL_AURA_ADD_PCT_MODIFIER, SPELLFAMILY_DEATHKNIGHT, 2751, 0)) AddPctN(bp, m_caster->CalculateSpellDamage(m_caster, aurEff->GetSpellInfo(), 2)); @@ -1465,12 +1469,12 @@ void Spell::EffectDummy(SpellEffIndex effIndex) { if (m_caster->IsFriendlyTo(unitTarget)) { - int32 bp = int32(damage * 1.5f); + bp = int32(damage * 1.5f); m_caster->CastCustomSpell(unitTarget, 47633, &bp, NULL, NULL, true); } else { - int32 bp = damage; + bp = damage; m_caster->CastCustomSpell(unitTarget, 47632, &bp, NULL, NULL, true); } return; @@ -6348,13 +6352,13 @@ void Spell::EffectQuestClear(SpellEffIndex effIndex) // remove all quest entries for 'entry' from quest log for (uint8 slot = 0; slot < MAX_QUEST_LOG_SIZE; ++slot) { - uint32 quest = player->GetQuestSlotQuestId(slot); - if (quest == quest_id) + uint32 logQuest = player->GetQuestSlotQuestId(slot); + if (logQuest == quest_id) { player->SetQuestSlot(slot, 0); - // we ignore unequippable quest items in this case, its' still be equipped - player->TakeQuestSourceItem(quest, false); + // we ignore unequippable quest items in this case, it's still be equipped + player->TakeQuestSourceItem(logQuest, false); } } |