diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index da110d65bf..cc35744cf6 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -75,7 +75,7 @@ fabric-minecraft = "com.mojang:minecraft:1.20.6" fabric-loader = "net.fabricmc:fabric-loader:0.15.10" fabric-permissions-api = "me.lucko:fabric-permissions-api:0.3.1" -neoforge = "net.neoforged:neoforge:20.6.42-beta" +neoforge = "net.neoforged:neoforge:20.6.88-beta" # Mojang-provided libraries, CHECK AGAINST MINECRAFT for versions guava = "com.google.guava:guava:32.1.3-jre!!" diff --git a/worldedit-neoforge/src/main/java/com/sk89q/worldedit/neoforge/NeoForgeWorldEdit.java b/worldedit-neoforge/src/main/java/com/sk89q/worldedit/neoforge/NeoForgeWorldEdit.java index 4cd46b2121..9f3d0beb77 100644 --- a/worldedit-neoforge/src/main/java/com/sk89q/worldedit/neoforge/NeoForgeWorldEdit.java +++ b/worldedit-neoforge/src/main/java/com/sk89q/worldedit/neoforge/NeoForgeWorldEdit.java @@ -61,7 +61,6 @@ import net.minecraft.world.InteractionHand; import net.minecraft.world.entity.player.Player; import net.minecraft.world.level.biome.Biome; -import net.neoforged.bus.api.Event; import net.neoforged.bus.api.IEventBus; import net.neoforged.bus.api.SubscribeEvent; import net.neoforged.fml.ModContainer; @@ -278,7 +277,7 @@ private boolean skipInteractionEvent(Player player, InteractionHand hand) { @SubscribeEvent public void onLeftClickBlock(PlayerInteractEvent.LeftClickBlock event) { - if (skipInteractionEvent(event.getEntity(), event.getHand()) || event.getUseItem() == Event.Result.DENY) { + if (skipInteractionEvent(event.getEntity(), event.getHand()) || event.getUseItem().isFalse()) { return; } @@ -301,7 +300,7 @@ public void onLeftClickBlock(PlayerInteractEvent.LeftClickBlock event) { @SubscribeEvent public void onRightClickBlock(PlayerInteractEvent.RightClickBlock event) { - if (skipInteractionEvent(event.getEntity(), event.getHand()) || event.getUseItem() == Event.Result.DENY) { + if (skipInteractionEvent(event.getEntity(), event.getHand()) || event.getUseItem().isFalse()) { return; }