Update from upstream SpigotMC
Remove defensive copy in EAR SpigotMC/Spigot@f1ba1f6c07 Make "moved wrongly limit" configurable SpigotMC/Spigot@f7ab380e16 Fix null Tile Entity Worlds (we already had this) SpigotMC/Spigot@b271cdbfa0 Fix slow tab complete for some commands SpigotMC/Spigot@f3b7952c73 Only suggest ops to deop and remove whitelist add case entirely SpigotMC/Spigot@0e1fcfbe70 Allow tab complete for /whitelist add SpigotMC/Spigot@27f8aa22bd
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jonas Konrad <me@yawk.at>
|
||||
Date: Fri, 4 Jul 2014 23:03:13 +0200
|
||||
Subject: [PATCH] Make "moved wrongly" limit configurable
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketPlayInListener {
|
||||
d10 = d4 * d4 + d5 * d5 + d6 * d6;
|
||||
boolean flag1 = false;
|
||||
|
||||
- if (d10 > 0.0625D && !this.player.isSleeping() && !this.player.playerInteractManager.isCreative()) {
|
||||
+ // Spigot: make "moved wrongly" limit configurable
|
||||
+ if (d10 > org.spigotmc.SpigotConfig.movedWronglyThreshold && !this.player.isSleeping() && !this.player.playerInteractManager.isCreative()) {
|
||||
flag1 = true;
|
||||
c.warn(this.player.getName() + " moved wrongly!");
|
||||
}
|
||||
diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/org/spigotmc/SpigotConfig.java
|
||||
+++ b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||
@@ -0,0 +0,0 @@ public class SpigotConfig
|
||||
{
|
||||
intCacheLimit = getInt( "settings.int-cache-limit", 1024 );
|
||||
}
|
||||
+
|
||||
+ private static double getDouble(String path, double def)
|
||||
+ {
|
||||
+ config.addDefault( path, def );
|
||||
+ return config.getDouble( path, config.getDouble( path ) );
|
||||
+ }
|
||||
+
|
||||
+ public static double movedWronglyThreshold;
|
||||
+ private static void movedWronglyThreshold()
|
||||
+ {
|
||||
+ movedWronglyThreshold = getDouble( "settings.moved-wrongly-threshold", 0.0625D );
|
||||
+ }
|
||||
}
|
||||
--
|
||||
Reference in New Issue
Block a user