Skip to content

Commit

Permalink
Shovel can be use on path block
Browse files Browse the repository at this point in the history
  • Loading branch information
lebonq committed Oct 14, 2021
1 parent 4e27c9a commit f21e9b3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ org.gradle.jvmargs = -Xmx3G

#Fabric properties
minecraft_version=1.17.1
yarn_mappings=1.17.1+build.40
yarn_mappings=1.17.1+build.61
loader_version=0.11.6
#Mod properties
mod_version = 1.4.5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,14 @@

import java.util.Iterator;

import net.minecraft.block.*;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;

import fr.lebon.autopath.AutoPath;
import fr.lebon.autopath.blocks.PathBlock;
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.block.SugarCaneBlock;
import net.minecraft.fluid.FluidState;
import net.minecraft.tag.FluidTags;
import net.minecraft.util.math.BlockPos;
Expand All @@ -27,7 +25,6 @@ public class PathBlockSugarCane {
@Inject(method = "canPlaceAt", at = @At("TAIL"), cancellable = true)
private void test(BlockState state, WorldView world, BlockPos pos, CallbackInfoReturnable<Boolean> cir) {
BlockState blockState = world.getBlockState(pos.down());

boolean trigger = false;

if (blockState.isOf(AutoPath.PATH_BLOCK)) {
Expand Down

0 comments on commit f21e9b3

Please sign in to comment.