From c89f7209e95a89de234770acfd01d22eccaa9a9c Mon Sep 17 00:00:00 2001 From: Sollace Date: Tue, 8 Oct 2024 15:10:06 +0100 Subject: [PATCH] Fixed not being able to collect water from soggy cloud stairs --- .../unicopia/block/cloud/SoggyCloudStairsBlock.java | 11 +++++++++++ .../unicopia/block/jar/FluidOnlyJarContents.java | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java index 9e51e398..2efff68b 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java +++ b/src/main/java/com/minelittlepony/unicopia/block/cloud/SoggyCloudStairsBlock.java @@ -8,10 +8,15 @@ import com.minelittlepony.unicopia.block.state.StateUtil; import net.minecraft.block.Block; import net.minecraft.block.BlockState; +import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemStack; import net.minecraft.state.StateManager; +import net.minecraft.util.ActionResult; +import net.minecraft.util.Hand; +import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.math.BlockPos; import net.minecraft.world.BlockView; +import net.minecraft.world.World; public class SoggyCloudStairsBlock extends CloudStairsBlock implements Soakable { @@ -34,6 +39,12 @@ public class SoggyCloudStairsBlock extends CloudStairsBlock implements Soakable return dryBlock.get().getPickStack(world, pos, state); } + @Deprecated + @Override + public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { + return Soakable.tryCollectMoisture(state, world, pos, player, hand, hit); + } + @Nullable @Override public BlockState getStateWithMoisture(BlockState state, int moisture) { diff --git a/src/main/java/com/minelittlepony/unicopia/block/jar/FluidOnlyJarContents.java b/src/main/java/com/minelittlepony/unicopia/block/jar/FluidOnlyJarContents.java index 49f0e62f..b3ac0222 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/jar/FluidOnlyJarContents.java +++ b/src/main/java/com/minelittlepony/unicopia/block/jar/FluidOnlyJarContents.java @@ -5,7 +5,7 @@ import com.minelittlepony.unicopia.block.ItemJarBlock.JarContents; import com.minelittlepony.unicopia.block.ItemJarBlock.TileData; import com.minelittlepony.unicopia.util.FluidHelper; -import net.fabricmc.fabric.api.tag.convention.v2.ConventionalItemTags; +import net.fabricmc.fabric.api.tag.convention.v1.ConventionalItemTags; import net.fabricmc.fabric.api.transfer.v1.fluid.FluidConstants; import net.fabricmc.fabric.api.transfer.v1.fluid.FluidVariant; import net.minecraft.entity.player.PlayerEntity;