Fixed model

This commit is contained in:
2025-11-12 20:39:00 +01:00
parent 5ff2e55d79
commit 16fcd92372
@@ -52,13 +52,18 @@ public class CableBlock extends Block {
protected VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) { protected VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) {
VoxelShape shape = Block.createCuboidShape(6, 6, 6, 10, 10, 10); VoxelShape shape = Block.createCuboidShape(6, 6, 6, 10, 10, 10);
if (state.get(NORTH)) boolean north = state.get(NORTH);
boolean south = state.get(SOUTH);
boolean east = state.get(EAST);
boolean west = state.get(WEST);
if (north)
shape = VoxelShapes.union(shape, Block.createCuboidShape(6, 6, 0, 10, 10, 6)); shape = VoxelShapes.union(shape, Block.createCuboidShape(6, 6, 0, 10, 10, 6));
if (state.get(SOUTH)) if (south)
shape = VoxelShapes.union(shape, Block.createCuboidShape(6, 6, 10, 10, 10, 16)); shape = VoxelShapes.union(shape, Block.createCuboidShape(6, 6, 10, 10, 10, 16));
if (state.get(EAST)) if (east)
shape = VoxelShapes.union(shape, Block.createCuboidShape(10, 6, 6, 16, 10, 10)); shape = VoxelShapes.union(shape, Block.createCuboidShape(10, 6, 6, 16, 10, 10));
if (state.get(WEST)) if (west)
shape = VoxelShapes.union(shape, Block.createCuboidShape(0, 6, 6, 6, 10, 10)); shape = VoxelShapes.union(shape, Block.createCuboidShape(0, 6, 6, 6, 10, 10));
return shape; return shape;