Skip to content

Commit

Permalink
Update max placement height for scarecrows
Browse files Browse the repository at this point in the history
  • Loading branch information
Thodor12 authored Jan 1, 2025
1 parent a763630 commit 95421a8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ public BlockState getStateForPlacement(final BlockPlaceContext context)
{
@NotNull final Direction dir = (context.getPlayer() == null) ? Direction.NORTH : Direction.fromYRot(context.getPlayer().getYRot() + 180);

if (context.getClickedPos().getY() < 255 && context.getLevel().getBlockState(context.getClickedPos().above()).canBeReplaced(context))
if (context.getClickedPos().getY() < context.getLevel().getMaxBuildHeight() && context.getLevel().getBlockState(context.getClickedPos().above()).canBeReplaced(context))
{
return this.defaultBlockState().setValue(FACING, dir).setValue(HALF, DoubleBlockHalf.LOWER);
}
Expand Down

0 comments on commit 95421a8

Please sign in to comment.