mirror of
https://github.com/Sollace/Unicopia.git
synced 2024-11-24 05:47:59 +01:00
Spikes no longer pop off of honey blocks
This commit is contained in:
parent
9b94662f9b
commit
3e9a0df7a1
1 changed files with 2 additions and 3 deletions
|
@ -60,7 +60,7 @@ public class SpikesBlock extends OrientedBlock {
|
||||||
Direction facing = state.get(FACING);
|
Direction facing = state.get(FACING);
|
||||||
pos = pos.offset(facing.getOpposite());
|
pos = pos.offset(facing.getOpposite());
|
||||||
state = world.getBlockState(pos);
|
state = world.getBlockState(pos);
|
||||||
return state.isReplaceable() || state.isSideSolid(world, pos, facing, SideShapeType.FULL);
|
return state.isReplaceable() || state.isSideSolid(world, pos, facing, SideShapeType.FULL) || state.isOf(Blocks.HONEY_BLOCK);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -72,8 +72,7 @@ public class SpikesBlock extends OrientedBlock {
|
||||||
@Deprecated
|
@Deprecated
|
||||||
@Override
|
@Override
|
||||||
public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) {
|
public BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState neighborState, WorldAccess world, BlockPos pos, BlockPos neighborPos) {
|
||||||
if (direction == state.get(FACING).getOpposite() && !neighborState.isSideSolid(world, neighborPos, direction, SideShapeType.FULL)) {
|
if (direction == state.get(FACING).getOpposite() && !canPlaceAt(state, world, pos)) {
|
||||||
|
|
||||||
if (!(neighborState.isOf(Blocks.STICKY_PISTON)
|
if (!(neighborState.isOf(Blocks.STICKY_PISTON)
|
||||||
|| neighborState.isOf(Blocks.PISTON)
|
|| neighborState.isOf(Blocks.PISTON)
|
||||||
|| neighborState.isOf(Blocks.PISTON_HEAD)
|
|| neighborState.isOf(Blocks.PISTON_HEAD)
|
||||||
|
|
Loading…
Reference in a new issue