mirror of
https://github.com/cabaletta/baritone
synced 2025-02-16 11:57:04 +00:00
Merge branch '1.14.4' into 1.15.2
This commit is contained in:
commit
34501f5af3
@ -39,6 +39,7 @@ import net.minecraft.util.math.RayTraceResult;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
import static baritone.pathing.movement.Movement.HORIZONTALS_BUT_ALSO_DOWN_____SO_EVERY_DIRECTION_EXCEPT_UP;
|
||||
@ -522,7 +523,12 @@ public interface MovementHelper extends ActionCosts, Helper {
|
||||
|| block instanceof ShulkerBoxBlock) {
|
||||
return false;
|
||||
}
|
||||
return Block.isOpaque(state.getCollisionShape(null, null));
|
||||
try {
|
||||
return Block.isOpaque(state.getCollisionShape(null, null));
|
||||
} catch (Exception ignored) {
|
||||
// if we can't get the collision shape, assume it's bad and add to blocksToAvoid
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
static PlaceResult attemptToPlaceABlock(MovementState state, IBaritone baritone, BlockPos placeAt, boolean preferDown, boolean wouldSneak) {
|
||||
|
Loading…
Reference in New Issue
Block a user