diff options
author | DarkoGNU <42816979+DarkoGNU@users.noreply.github.com> | 2022-06-28 23:49:41 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-28 23:49:41 +0200 |
commit | 25208aefa4232a7e90198adbc542ec8b7c584c70 (patch) | |
tree | 3fbbc14c6d6e2c42d44d7521f430a7f8725bc266 /src/Blocks/BlockFarmland.h | |
parent | Fix building with clang 14 (#5428) (diff) | |
download | cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar.gz cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar.bz2 cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar.lz cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar.xz cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.tar.zst cuberite-25208aefa4232a7e90198adbc542ec8b7c584c70.zip |
Diffstat (limited to 'src/Blocks/BlockFarmland.h')
-rw-r--r-- | src/Blocks/BlockFarmland.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/Blocks/BlockFarmland.h b/src/Blocks/BlockFarmland.h index 3da27de43..9a458a1d6 100644 --- a/src/Blocks/BlockFarmland.h +++ b/src/Blocks/BlockFarmland.h @@ -46,8 +46,10 @@ public: */ static void TurnToDirt(cChunk & a_Chunk, const Vector3i a_AbsPos, const Vector3i a_RelPos) { - static const auto FarmlandHeight = cBlockInfo::GetBlockHeight(E_BLOCK_FARMLAND); - static const auto FullHeightDelta = 1 - FarmlandHeight; + // Use cBlockInfo::GetBlockHeight when it doesn't break trampling for + // mobs and older clients anymore + static const auto FarmlandHeight = 0.9375; + static const auto FullHeightDelta = 0.0625; a_Chunk.ForEachEntityInBox( cBoundingBox(Vector3d(0.5, FarmlandHeight, 0.5) + a_AbsPos, 0.5, FullHeightDelta), |