Core/Spells: Use a workaround for Grab Crate, cast triggered spell with original caster as caster instead of target. Previous approach was prone to out of range errors.

Spell will now correctly restore 25 Pyrite energy (assuming aura 62495 is present to trigger the initial handler)

--HG--
branch : trunk
This commit is contained in:
Machiavelli
2010-12-25 03:18:21 +01:00
parent 06955a1113
commit d587948a0f

View File

@@ -5070,7 +5070,7 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex)
if (Creature *oldContainer = dynamic_cast<Creature*>(seat->GetPassenger(1)))
oldContainer->DisappearAndDie();
// TODO: a hack, range = 11, should after some time cast, otherwise too far
unitTarget->CastSpell(seat->GetBase(), 62496, true);
m_caster->CastSpell(seat->GetBase(), 62496, true);
unitTarget->EnterVehicle(seat, 1);
}
}