From 4f0e9945c6ae8ae9076195e9f51276b23aa59f09 Mon Sep 17 00:00:00 2001 From: Paul Coene Date: Thu, 23 Dec 2021 15:01:56 -0500 Subject: [PATCH] [Combat] Allow npcs/pets to kick vs opponents requiring magic weapons if wearing magic booties. (#1868) * [Pets/NPC Kick] Allow pets/npcs kick vs mobs that req magic if using magic boots * Backout accidental change to bash --- zone/special_attacks.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/zone/special_attacks.cpp b/zone/special_attacks.cpp index 1e86a6792..5116eb481 100644 --- a/zone/special_attacks.cpp +++ b/zone/special_attacks.cpp @@ -1617,6 +1617,8 @@ void NPC::DoClassAttacks(Mob *target) { bool ca_time = classattack_timer.Check(false); bool ka_time = knightattack_timer.Check(false); + const EQ::ItemData* boots = database.GetItem(equipment[EQ::invslot::slotFeet]); + //only check attack allowed if we are going to do something if((taunt_time || ca_time || ka_time) && !IsAttackAllowed(target)) return; @@ -1688,7 +1690,7 @@ void NPC::DoClassAttacks(Mob *target) { DoAnim(animKick, 0, false); int32 dmg = GetBaseSkillDamage(EQ::skills::SkillKick); - if (GetWeaponDamage(target, (const EQ::ItemData*)nullptr) <= 0) { + if (GetWeaponDamage(target, boots) <= 0) { dmg = DMG_INVULNERABLE; } @@ -1739,7 +1741,7 @@ void NPC::DoClassAttacks(Mob *target) { DoAnim(animKick, 0, false); int32 dmg = GetBaseSkillDamage(EQ::skills::SkillKick); - if (GetWeaponDamage(target, (const EQ::ItemData*)nullptr) <= 0) + if (GetWeaponDamage(target, boots) <= 0) dmg = DMG_INVULNERABLE; reuse = (KickReuseTime + 3) * 1000;