--- a/net/minecraft/world/item/DebugStickItem.java +++ b/net/minecraft/world/item/DebugStickItem.java @@ -1,3 +1,4 @@ +// mc-dev import package net.minecraft.world.item; import java.util.Collection; @@ -52,7 +53,7 @@ } public boolean handleInteraction(Player player, BlockState state, LevelAccessor world, BlockPos pos, boolean update, ItemStack stack) { - if (!player.canUseGameMasterBlocks()) { + if (!player.canUseGameMasterBlocks() && !(player.getAbilities().instabuild && player.getBukkitEntity().hasPermission("minecraft.debugstick")) && !player.getBukkitEntity().hasPermission("minecraft.debugstick.always")) { // Spigot return false; } else { Holder holder = state.getBlockHolder(); @@ -92,7 +93,7 @@ } private static > BlockState cycleState(BlockState state, Property property, boolean inverse) { - return (BlockState) state.setValue(property, (Comparable) DebugStickItem.getRelative(property.getPossibleValues(), state.getValue(property), inverse)); + return (BlockState) state.setValue(property, DebugStickItem.getRelative(property.getPossibleValues(), state.getValue(property), inverse)); // CraftBukkit - decompile error } private static T getRelative(Iterable elements, @Nullable T current, boolean inverse) {