diff --git a/Spigot-Server-Patches/Configurable-TNT-explosion-volume.patch b/Spigot-Server-Patches/Configurable-TNT-explosion-volume.patch index 0de227ffd3..4df7c1f629 100644 --- a/Spigot-Server-Patches/Configurable-TNT-explosion-volume.patch +++ b/Spigot-Server-Patches/Configurable-TNT-explosion-volume.patch @@ -26,13 +26,13 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 +++ b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java @@ -0,0 +0,0 @@ public class PaperSpigotWorldConfig { - containerUpdateTickRate = getInt("container-update-tick-rate", 1); + containerUpdateTickRate = getInt( "container-update-tick-rate", 1 ); } + + public float tntExplosionVolume; + private void tntExplosionVolume() + { -+ tntExplosionVolume = getFloat("tnt-explosion-volume", 4.0F); ++ tntExplosionVolume = getFloat( "tnt-explosion-volume", 4.0F ); + } } -- \ No newline at end of file diff --git a/Spigot-Server-Patches/PaperSpigot-config-files.patch b/Spigot-Server-Patches/PaperSpigot-config-files.patch index 0520b4e720..9bef7d19ba 100644 --- a/Spigot-Server-Patches/PaperSpigot-config-files.patch +++ b/Spigot-Server-Patches/PaperSpigot-config-files.patch @@ -211,8 +211,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + + private static float getFloat(String path, float def) + { -+ config.addDefault( path, def ); -+ return config.getFloat( path, config.getFloat( path ) ); ++ // TODO: Figure out why getFloat() always returns the default value. ++ return (float) getDouble( path, (double) def ); + } + + private static int getInt(String path, int def) @@ -300,8 +300,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + + private float getFloat(String path, float def) + { -+ config.addDefault( "world-settings.default." + path, def ); -+ return config.getFloat( "world-settings." + worldName + "." + path, config.getFloat( "world-settings.default." + path ) ); ++ // TODO: Figure out why getFloat() always returns the default value. ++ return (float) getDouble( path, (double) def ); + } + + private List getList(String path, T def)