Fixed chitin blocks not orienting constently

This commit is contained in:
Sollace 2020-05-05 22:25:24 +02:00
parent abbba5dc68
commit f5cfe302a5

View file

@ -40,9 +40,7 @@ public class ChiselledChitinBlock extends Block {
@Nullable @Nullable
public BlockState getPlacementState(ItemPlacementContext context) { public BlockState getPlacementState(ItemPlacementContext context) {
PlayerEntity player = context.getPlayer(); PlayerEntity player = context.getPlayer();
Direction direction = context.getSide();
Direction direction = player == null ? context.getSide() : context.getPlayerLookDirection().getOpposite();
if (player != null && player.isSneaking()) { if (player != null && player.isSneaking()) {
direction = direction.getOpposite(); direction = direction.getOpposite();