From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
Date: Thu, 27 Feb 2020 21:42:19 -0600
Subject: [PATCH] Configurable void damage height


diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 4e6ec59c982fe0870f514b59082ab0a7de4d93ef..b114d12d9d17071fb96f5ab225b85cdd5ad06861 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -719,7 +719,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne
 
     // Paper start
     protected void performVoidDamage() {
-        if (this.locY() < -64.0D || (this.world.getWorld().getEnvironment() == org.bukkit.World.Environment.NETHER
+        if (this.locY() < world.purpurConfig.voidDamageHeight || (this.world.getWorld().getEnvironment() == org.bukkit.World.Environment.NETHER // Purpur
             && world.paperConfig.doNetherTopVoidDamage()
             && this.locY() >= world.paperConfig.netherVoidTopDamageHeight)) {
             this.doVoidDamage();
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
index e10aa8ddbcea3588b2da08de929eed18cb9f022c..ef5a691861cdf249f0430fca7f7bbe241479926e 100644
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
@@ -116,11 +116,13 @@ public class PurpurWorldConfig {
     public boolean entitiesPickUpLootBypassMobGriefing = false;
     public boolean milkCuresBadOmen = true;
     public double tridentLoyaltyVoidReturnHeight = 0.0D;
+    public double voidDamageHeight = -64.0D;
     private void miscGameplayMechanicsSettings() {
         disableDropsOnCrammingDeath = getBoolean("gameplay-mechanics.disable-drops-on-cramming-death", disableDropsOnCrammingDeath);
         entitiesPickUpLootBypassMobGriefing = getBoolean("gameplay-mechanics.entities-pick-up-loot-bypass-mob-griefing", entitiesPickUpLootBypassMobGriefing);
         milkCuresBadOmen = getBoolean("gameplay-mechanics.milk-cures-bad-omen", milkCuresBadOmen);
         tridentLoyaltyVoidReturnHeight = getDouble("gameplay-mechanics.trident-loyalty-void-return-height", tridentLoyaltyVoidReturnHeight);
+        voidDamageHeight = getDouble("gameplay-mechanics.void-damage-height", voidDamageHeight);
     }
 
     public String playerDeathExpDropEquation = "expLevel * 7";
