diff --git a/mobzy-pathfinding/src/main/kotlin/com/mineinabyss/mobzy/pathfinding/bindings/goals/MeleeAttackBehavior.kt b/mobzy-pathfinding/src/main/kotlin/com/mineinabyss/mobzy/pathfinding/bindings/goals/MeleeAttackBehavior.kt index fe49cd91..ccf17401 100644 --- a/mobzy-pathfinding/src/main/kotlin/com/mineinabyss/mobzy/pathfinding/bindings/goals/MeleeAttackBehavior.kt +++ b/mobzy-pathfinding/src/main/kotlin/com/mineinabyss/mobzy/pathfinding/bindings/goals/MeleeAttackBehavior.kt @@ -1,11 +1,9 @@ package com.mineinabyss.mobzy.pathfinding.bindings.goals import com.mineinabyss.idofront.nms.aliases.toNMS -import com.mineinabyss.mobzy.modelengine.animation.playAnimation import com.mineinabyss.mobzy.pathfinding.components.PathfinderComponent import kotlinx.serialization.SerialName import kotlinx.serialization.Serializable -import net.minecraft.world.entity.LivingEntity import net.minecraft.world.entity.PathfinderMob import org.bukkit.entity.Mob import net.minecraft.world.entity.ai.goal.MeleeAttackGoal as NMSMeleeAttackGoal @@ -22,14 +20,6 @@ class MeleeAttackBehavior( inner class MeleeAttackGoal( private val entity: Mob ) : NMSMeleeAttackGoal(entity.toNMS(), attackSpeed, seeThroughWalls) { - override fun checkAndPerformAttack(target: LivingEntity/*, squaredDistance: Double*/) { - val width = mob.bbWidth - val d = (1 + width) * (1 + width) + target.bbWidth - if (/*squaredDistance <= d && */ticksUntilNextAttack <= 0) { - entity.playAnimation("attack", 0.0, 0.0, 1.0, false) - resetAttackCooldown() - mob.doHurtTarget(target) - } - } + } }