From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: tr7zw Date: Tue, 4 Aug 2020 22:08:09 +0200 Subject: [PATCH] Fix lead fall dmg config diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java index 32372e46103958e985582796964a47120ec9c1a3..b742f457d72eee4f00f5df7a2b5b3cfdeb917a86 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -1451,6 +1451,8 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne this.fallDistance = 0.0F; } else if (d0 < 0.0D) { this.fallDistance = (float) ((double) this.fallDistance - d0); + } else if (d0 > 0.0D && org.yatopiamc.yatopia.server.YatopiaConfig.fixFallDistance) { // Yatopia + this.fallDistance = 0.0F; // Yatopia } } diff --git a/src/main/java/org/yatopiamc/yatopia/server/YatopiaConfig.java b/src/main/java/org/yatopiamc/yatopia/server/YatopiaConfig.java index f318508a4c2a6376b00d55886f313fd4e007c14f..50f232c956f68d3d9c3eaf645810e38d805f4531 100644 --- a/src/main/java/org/yatopiamc/yatopia/server/YatopiaConfig.java +++ b/src/main/java/org/yatopiamc/yatopia/server/YatopiaConfig.java @@ -201,4 +201,9 @@ public class YatopiaConfig { simplerVillagerBehavior = getBoolean("settings.villager.simplerVillagerBehavior", false); villagersHideAtNight = getBoolean("settings.villager.villagersHideAtNight", false); } + + public static boolean fixFallDistance = false; + private static void fixFallDistance() { + fixFallDistance = getBoolean("settings.fixFallDistance", false); + } }