From b8575c4a67efeffa4059eda64d7689b9ee692e4a Mon Sep 17 00:00:00 2001 From: Flanks255 <32142731+Flanks255@users.noreply.github.com> Date: Tue, 5 Nov 2024 15:36:52 -0600 Subject: [PATCH] Fixed the drill breaking when out of energy, closes #1432 --- CHANGELOG.md | 1 + .../java/de/ellpeck/actuallyadditions/mod/items/DrillItem.java | 2 +- .../de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java | 1 - 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a3e9c7ed7..f3cf96bac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # 1.3.9+mc1.21.1 * Change laser rendering to be compatible with Iris * Fix machines in the Engineer House being obtainable when broken +* Fixed the drill breaking when out of energy. # 1.3.8+mc1.21.1 * Lock the Immersive Engineering cloche compat recipes behind a mod loaded condition diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/DrillItem.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/DrillItem.java index 8f62897ee..c147d5e78 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/DrillItem.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/DrillItem.java @@ -39,6 +39,7 @@ import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.Tiers; import net.minecraft.world.item.component.ItemAttributeModifiers; import net.minecraft.world.item.component.ItemContainerContents; +import net.minecraft.world.item.component.Unbreakable; import net.minecraft.world.item.context.UseOnContext; import net.minecraft.world.item.enchantment.Enchantments; import net.minecraft.world.level.Level; @@ -68,7 +69,6 @@ public class DrillItem extends ItemEnergy { public DrillItem() { super(ActuallyItems.defaultProps() - .durability(0) .stacksTo(1) .component(DataComponents.TOOL, Tiers.NETHERITE.createToolProperties(ActuallyTags.Blocks.MINEABLE_WITH_DRILL)) , 250000, 1000); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java index 2eb0c3ae4..63897cb1a 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java @@ -31,7 +31,6 @@ import java.util.List; import java.util.Optional; public abstract class ItemEnergy extends ItemBase { - public final int maxPower; public final int transfer;