From f1c87ed5ad485629558e518a643ddc2f19336847 Mon Sep 17 00:00:00 2001 From: DBotThePony Date: Sun, 9 Mar 2025 16:22:11 +0700 Subject: [PATCH] Specify effect source as attacker in Wither Steel Sword --- .../ru/dbotthepony/mc/otm/item/weapon/WitheredSteelSwordItem.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/ru/dbotthepony/mc/otm/item/weapon/WitheredSteelSwordItem.kt b/src/main/kotlin/ru/dbotthepony/mc/otm/item/weapon/WitheredSteelSwordItem.kt index 60101524a..7de70f248 100644 --- a/src/main/kotlin/ru/dbotthepony/mc/otm/item/weapon/WitheredSteelSwordItem.kt +++ b/src/main/kotlin/ru/dbotthepony/mc/otm/item/weapon/WitheredSteelSwordItem.kt @@ -38,7 +38,7 @@ class WitheredSteelSwordItem(properties: Properties) : SwordItem(Tiers.IRON, pro override fun hurtEnemy(stack: ItemStack, target: LivingEntity, attacker: LivingEntity): Boolean { val status = super.hurtEnemy(stack, target, attacker) - if (status) target.addEffect(MobEffectInstance(MobEffects.WITHER, 100, 0)) + if (status) target.addEffect(MobEffectInstance(MobEffects.WITHER, 100, 0), attacker) return status }