mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-20 01:15:35 +01:00
*use OriginalVictim for some range based spell casts (only scripts)
-fixed void reaver's arcane orb spell, now it is shown in combatlog (cheers to bossmods) --HG-- branch : trunk
This commit is contained in:
@@ -1183,7 +1183,7 @@ void Unit::CastCustomSpell(uint32 spellId, CustomSpellValues const &value, Unit*
|
||||
}
|
||||
|
||||
// used for scripting
|
||||
void Unit::CastSpell(float x, float y, float z, uint32 spellId, bool triggered, Item *castItem, AuraEffect* triggeredByAura, uint64 originalCaster)
|
||||
void Unit::CastSpell(float x, float y, float z, uint32 spellId, bool triggered, Item *castItem, AuraEffect* triggeredByAura, uint64 originalCaster, Unit* OriginalVictim)
|
||||
{
|
||||
SpellEntry const *spellInfo = sSpellStore.LookupEntry(spellId );
|
||||
|
||||
@@ -1203,6 +1203,8 @@ void Unit::CastSpell(float x, float y, float z, uint32 spellId, bool triggered,
|
||||
|
||||
SpellCastTargets targets;
|
||||
targets.setDestination(x, y, z);
|
||||
if(OriginalVictim)
|
||||
targets.setUnitTarget(OriginalVictim);
|
||||
spell->m_CastItem = castItem;
|
||||
spell->prepare(&targets, triggeredByAura);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user