From 7d8117083f8c38146f5f99cab0d330143b5ed7d3 Mon Sep 17 00:00:00 2001 From: Shane Freeder Date: Sun, 15 Dec 2019 19:42:35 +0000 Subject: [PATCH] Fix spawn radius being treated as 0 (Fixes #2742) --- ...-Fix-spawn-radius-being-treated-as-0.patch | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Spigot-Server-Patches/0415-Fix-spawn-radius-being-treated-as-0.patch diff --git a/Spigot-Server-Patches/0415-Fix-spawn-radius-being-treated-as-0.patch b/Spigot-Server-Patches/0415-Fix-spawn-radius-being-treated-as-0.patch new file mode 100644 index 0000000000..6aba109b0e --- /dev/null +++ b/Spigot-Server-Patches/0415-Fix-spawn-radius-being-treated-as-0.patch @@ -0,0 +1,22 @@ +From e066283106f45fb528cc713204b965fbd789906c Mon Sep 17 00:00:00 2001 +From: Shane Freeder +Date: Sun, 15 Dec 2019 19:41:28 +0000 +Subject: [PATCH] Fix spawn radius being treated as 0 + + +diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java +index 30380c8db..d379bacac 100644 +--- a/src/main/java/net/minecraft/server/EntityPlayer.java ++++ b/src/main/java/net/minecraft/server/EntityPlayer.java +@@ -123,7 +123,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting { + public final BlockPosition getSpawnPoint(WorldServer worldserver) { + BlockPosition blockposition = worldserver.getSpawn(); + +- if (worldserver.worldProvider.g() && worldserver.getWorldData().getGameType() != EnumGamemode.ADVENTURE) { ++ if (worldserver.worldProvider.f() && worldserver.getWorldData().getGameType() != EnumGamemode.ADVENTURE) { // Paper + int i = Math.max(0, this.server.a(worldserver)); + int j = MathHelper.floor(worldserver.getWorldBorder().b((double) blockposition.getX(), (double) blockposition.getZ())); + +-- +2.24.1 +