diff options
| author | Nay <dnpd.dd@gmail.com> | 2012-08-04 17:14:53 -0700 |
|---|---|---|
| committer | Nay <dnpd.dd@gmail.com> | 2012-08-04 17:14:53 -0700 |
| commit | 332baef4f2680d4c055fd713b99609aeb00dbc64 (patch) | |
| tree | c10cffb18bed41dcdebf4e8a3a6ebc0de931d248 /src | |
| parent | f2c200ce3b03c4d1b4effadc2cfc9e0b1ad2e039 (diff) | |
| parent | bf6e334c5fd92933e66f099cec371129557ec2b1 (diff) | |
Merge pull request #7255 from Vincent-Michael/summonVehicle
Core/Spells: Fix some summon vehicle spells with basepoint 1
Diffstat (limited to 'src')
| -rwxr-xr-x | src/server/game/Spells/SpellEffects.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 95f67d05e9a..484d03f1504 100755 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -2420,12 +2420,13 @@ void Spell::EffectSummonType(SpellEffIndex effIndex) return; // The spell that this effect will trigger. It has SPELL_AURA_CONTROL_VEHICLE - uint32 spell = VEHICLE_SPELL_RIDE_HARDCODED; - if (SpellInfo const* spellProto = sSpellMgr->GetSpellInfo(m_spellInfo->Effects[effIndex].CalcValue())) - spell = spellProto->Id; + uint32 spellId = VEHICLE_SPELL_RIDE_HARDCODED; + SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(m_spellInfo->Effects[effIndex].CalcValue()); + if (spellInfo && spellInfo->HasAura(SPELL_AURA_CONTROL_VEHICLE)) + spellId = spellInfo->Id; // Hard coded enter vehicle spell - m_originalCaster->CastSpell(summon, spell, true); + m_originalCaster->CastSpell(summon, spellId, true); uint32 faction = properties->Faction; if (!faction) |
