diff options
author | ariel- <ariel-@users.noreply.github.com> | 2017-02-09 16:01:43 -0300 |
---|---|---|
committer | ariel- <ariel-@users.noreply.github.com> | 2017-02-09 16:01:43 -0300 |
commit | 149e449506abd75add8f9a73f744860e1e5ad0ae (patch) | |
tree | a82dd6068f9c8d2e1aa11d5790e20bb7779490ba /src | |
parent | 02633a332cf730984d17f422f0571458676e3604 (diff) |
Update spell_item.cpp
Small indent and codestyle fixes
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Spells/spell_item.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/server/scripts/Spells/spell_item.cpp b/src/server/scripts/Spells/spell_item.cpp index 53ad94a9fc5..8a030ebafdb 100644 --- a/src/server/scripts/Spells/spell_item.cpp +++ b/src/server/scripts/Spells/spell_item.cpp @@ -4602,7 +4602,7 @@ public: Unit* target = GetCaster(); if (target->getPowerType() == POWER_MANA) - availableElixirs.push_back(28509); // Elixir of Major Mageblood (22840) + availableElixirs.push_back(28509); // Elixir of Major Mageblood (22840) uint32 chosenElixir = Trinity::Containers::SelectRandomContainerElement(availableElixirs); @@ -4614,13 +4614,13 @@ public: if (sSpellMgr->IsSpellMemberOfSpellGroup(chosenElixir, SPELL_GROUP_ELIXIR_GUARDIAN)) chosenSpellGroup = SPELL_GROUP_ELIXIR_GUARDIAN; // If another spell of the same group is already active the elixir should not be cast - if (chosenSpellGroup) + if (chosenSpellGroup != SPELL_GROUP_NONE) { - Unit::AuraApplicationMap& Auras = target->GetAppliedAuras(); - for (Unit::AuraApplicationMap::iterator itr = Auras.begin(); itr != Auras.end(); ++itr) + Unit::AuraApplicationMap const& auraMap = target->GetAppliedAuras(); + for (auto itr = auraMap.begin(); itr != auraMap.end(); ++itr) { - uint32 spell_id = itr->second->GetBase()->GetId(); - if (sSpellMgr->IsSpellMemberOfSpellGroup(spell_id, chosenSpellGroup) && spell_id != chosenElixir) + uint32 spellId = itr->second->GetBase()->GetId(); + if (sSpellMgr->IsSpellMemberOfSpellGroup(spellId, chosenSpellGroup) && spellId != chosenElixir) { useElixir = false; break; |