[7990] Trigering "on hit" combat spell only at related to current hit weapon.

Also check at loading that only weapon item templates have "on hit" spell triggers.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
nos4r2zod 2009-06-11 01:24:25 +04:00 committed by VladimirMangos
parent e3fd03c7b9
commit 31957a22d6
5 changed files with 13 additions and 8 deletions

View file

@ -6828,8 +6828,9 @@ void Player::UpdateEquipSpellsAtFormChange()
}
}
void Player::CastItemCombatSpell(Item *item,Unit* Target, WeaponAttackType attType)
void Player::CastItemCombatSpell(Unit* Target, WeaponAttackType attType)
{
Item *item = GetWeaponForAttack(attType, true);
if(!item || item->IsBroken())
return;