Allow 0 entity trackign range. Use at own risk
Dieser Commit ist enthalten in:
Ursprung
e710c42e46
Commit
829a3e9181
@ -1,4 +1,4 @@
|
|||||||
From 9562c98d051c1af7030a149902c5f5326584e84f Mon Sep 17 00:00:00 2001
|
From 4c3900fbf24c986c9f13dadaf9bca06e1794dac2 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Wed, 20 Feb 2013 11:58:47 -0500
|
Date: Wed, 20 Feb 2013 11:58:47 -0500
|
||||||
Subject: [PATCH] Entity Tracking Ranges
|
Subject: [PATCH] Entity Tracking Ranges
|
||||||
@ -78,7 +78,7 @@ index 94cb855..fe7b8b0 100644
|
|||||||
|
|
||||||
public Block getBlockAt(int x, int y, int z) {
|
public Block getBlockAt(int x, int y, int z) {
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Spigot.java b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Spigot.java b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||||
index 4cbc796..fed3181 100644
|
index 4cbc796..2422d29 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||||
@@ -16,12 +16,16 @@ import net.minecraft.server.EntityComplexPart;
|
@@ -16,12 +16,16 @@ import net.minecraft.server.EntityComplexPart;
|
||||||
@ -98,7 +98,7 @@ index 4cbc796..fed3181 100644
|
|||||||
import net.minecraft.server.EntityPlayer;
|
import net.minecraft.server.EntityPlayer;
|
||||||
import net.minecraft.server.EntityProjectile;
|
import net.minecraft.server.EntityProjectile;
|
||||||
import net.minecraft.server.EntitySheep;
|
import net.minecraft.server.EntitySheep;
|
||||||
@@ -371,6 +375,32 @@ public class Spigot {
|
@@ -371,6 +375,30 @@ public class Spigot {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -122,9 +122,7 @@ index 4cbc796..fed3181 100644
|
|||||||
+ } else if (entity instanceof EntityItemFrame || entity instanceof EntityPainting || entity instanceof EntityItem || entity instanceof EntityExperienceOrb) {
|
+ } else if (entity instanceof EntityItemFrame || entity instanceof EntityPainting || entity instanceof EntityItem || entity instanceof EntityExperienceOrb) {
|
||||||
+ range = world.miscTrackingRange;
|
+ range = world.miscTrackingRange;
|
||||||
+ }
|
+ }
|
||||||
+ if (range == 0) {
|
+
|
||||||
+ return defaultRange;
|
|
||||||
+ }
|
|
||||||
+ return Math.min(world.maxTrackingRange, range);
|
+ return Math.min(world.maxTrackingRange, range);
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren