aboutsummaryrefslogtreecommitdiffhomepage
path: root/Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch
diff options
context:
space:
mode:
authorKyle Wood <[email protected]>2021-06-24 01:21:17 -0500
committerKyle Wood <[email protected]>2021-06-24 01:21:17 -0500
commit6ab98f8e35c9c941759ff1d15e15f66293c1983a (patch)
tree4635cf11ddcc351d65044664d17924067f373fb2 /Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch
parent216bd81bef963ff595eff88b68e9737977c40f66 (diff)
downloadPaper-6ab98f8e35c9c941759ff1d15e15f66293c1983a.tar.gz
Paper-6ab98f8e35c9c941759ff1d15e15f66293c1983a.zip
More changes for new paperweight
Diffstat (limited to 'Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch')
-rw-r--r--Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch24
1 files changed, 0 insertions, 24 deletions
diff --git a/Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch b/Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch
deleted file mode 100644
index ed7ce57a14..0000000000
--- a/Spigot-Server-Patches-Unmapped/0447-Restrict-vanilla-teleport-command-to-valid-locations.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Zach Brown <[email protected]>
-Date: Thu, 16 Apr 2020 20:07:29 -0500
-Subject: [PATCH] Restrict vanilla teleport command to valid locations
-
-Fixes GH-3165, GH-3575
-
-diff --git a/src/main/java/net/minecraft/server/commands/CommandTeleport.java b/src/main/java/net/minecraft/server/commands/CommandTeleport.java
-index b59763643def065cd998fa3005523c37973613fd..dcc92b0c9a7a0214a3e803d714c5e7078c17a039 100644
---- a/src/main/java/net/minecraft/server/commands/CommandTeleport.java
-+++ b/src/main/java/net/minecraft/server/commands/CommandTeleport.java
-@@ -142,6 +142,12 @@ public class CommandTeleport {
-
- private static void a(CommandListenerWrapper commandlistenerwrapper, Entity entity, WorldServer worldserver, double d0, double d1, double d2, Set<PacketPlayOutPosition.EnumPlayerTeleportFlags> set, float f, float f1, @Nullable CommandTeleport.a commandteleport_a) throws CommandSyntaxException {
- BlockPosition blockposition = new BlockPosition(d0, d1, d2);
-+ // Paper start - Don't allow teleport command to invalid locations
-+ if (d0 <= -30000000 || d2 <= -30000000 || d0 > 30000000 || d2 > 30000000 || d1 > 30000000 || d1 <= -30000000) { // Copy/pasta from BaseBlockPosition#isValidLocation
-+ org.bukkit.Bukkit.getLogger().warning("Refused to teleport " + entity.getName() + " to " + d0 + ", " + d1 + ", " + d2);
-+ return;
-+ }
-+ // Paper end
-
- if (!World.l(blockposition)) {
- throw CommandTeleport.a.create();