Mark bounding blocks as not allowing movement when queried by pathfinding
@@ -18,6 +18,7 @@ import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.fluid.IFluidState;
import net.minecraft.item.BlockItemUseContext;
import net.minecraft.item.ItemStack;
+import net.minecraft.pathfinding.PathType;
import net.minecraft.state.StateContainer;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.tileentity.TileEntityType;
@@ -236,4 +237,11 @@ public class BlockBounding extends Block implements IHasTileEntity<TileEntityBou
updateFluids(state, world, currentPos);
return super.updatePostPlacement(state, facing, facingState, world, currentPos, facingPos);
}
+
+ @Override
+ @Deprecated
+ public boolean allowsMovement(@Nonnull BlockState state, @Nonnull IBlockReader world, @Nonnull BlockPos pos, @Nonnull PathType type) {
+ //Mark that bounding blocks do not allow movement for use by AI pathing
+ return false;
+ }
}
\ No newline at end of file
