From 98714556a0ea8b1bffad87be8e654c04e6995537 Mon Sep 17 00:00:00 2001 From: Sollace Date: Tue, 28 May 2024 14:32:22 +0100 Subject: [PATCH] Fixed magic projectiles not affecting falling blocks --- .../unicopia/projectile/MagicProjectileEntity.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/minelittlepony/unicopia/projectile/MagicProjectileEntity.java b/src/main/java/com/minelittlepony/unicopia/projectile/MagicProjectileEntity.java index 8591048d..be5afd69 100644 --- a/src/main/java/com/minelittlepony/unicopia/projectile/MagicProjectileEntity.java +++ b/src/main/java/com/minelittlepony/unicopia/projectile/MagicProjectileEntity.java @@ -14,6 +14,7 @@ import com.minelittlepony.unicopia.entity.mob.UEntities; import com.minelittlepony.unicopia.item.UItems; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityType; +import net.minecraft.entity.FallingBlockEntity; import net.minecraft.entity.LivingEntity; import net.minecraft.entity.data.DataTracker; import net.minecraft.entity.data.TrackedData; @@ -207,7 +208,7 @@ public class MagicProjectileEntity extends ThrownItemEntity implements WeaklyOwn protected void onEntityHit(EntityHitResult hit) { Entity entity = hit.getEntity(); - if (EquinePredicates.IS_MAGIC_IMMUNE.test(entity)) { + if (!(entity instanceof FallingBlockEntity) && EquinePredicates.IS_MAGIC_IMMUNE.test(entity)) { return; }