From fd837723025ba70d0ca47f9719612041bf90e2df Mon Sep 17 00:00:00 2001 From: md_5 Date: Sat, 1 Feb 2014 18:14:48 +1100 Subject: [PATCH] Cap Entity Collisions Limit a single entity to colliding a max of configurable times per tick. This will alleviate issues where living entities are hoarded in 1x1 pens. --- .../0107-Cap-Entity-Collisions.patch | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/CraftBukkit-Patches/0107-Cap-Entity-Collisions.patch b/CraftBukkit-Patches/0107-Cap-Entity-Collisions.patch index 1eab625eaf..9fc9f74f84 100644 --- a/CraftBukkit-Patches/0107-Cap-Entity-Collisions.patch +++ b/CraftBukkit-Patches/0107-Cap-Entity-Collisions.patch @@ -1,4 +1,4 @@ -From 17ee69deb13c9e1861411aef9879ff667ed5ad25 Mon Sep 17 00:00:00 2001 +From db76c53f063cc8a9ba146d427bf2ee9562f48015 Mon Sep 17 00:00:00 2001 From: Aikar Date: Fri, 31 Jan 2014 11:18:34 -0500 Subject: [PATCH] Cap Entity Collisions @@ -7,10 +7,10 @@ Limit a single entity to colliding a max of configurable times per tick. This will alleviate issues where living entities are hoarded in 1x1 pens. diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java -index e147244..cd621c4 100644 +index 69331ff..4d09fdb 100644 --- a/src/main/java/net/minecraft/server/Entity.java +++ b/src/main/java/net/minecraft/server/Entity.java -@@ -1020,6 +1020,7 @@ public abstract class Entity { +@@ -1021,6 +1021,7 @@ public abstract class Entity { public void b_(EntityHuman entityhuman) {} @@ -46,17 +46,18 @@ index 35b2f75..ab28bd3 100644 } diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java -index 4cff009..8f23103 100644 +index 4cff009..979b315 100644 --- a/src/main/java/org/spigotmc/SpigotWorldConfig.java +++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java -@@ -271,4 +271,10 @@ public class SpigotWorldConfig +@@ -271,4 +271,11 @@ public class SpigotWorldConfig maxBulkChunk = getInt( "max-bulk-chunks", 5 ); log( "Sending up to " + maxBulkChunk + " chunks per packet" ); } + -+ public int maxCollisionsPerEntity = 8; -+ private void maxEntityCollision() { -+ maxCollisionsPerEntity = getInt( "max-entity-collisions", maxCollisionsPerEntity ); ++ public int maxCollisionsPerEntity; ++ private void maxEntityCollision() ++ { ++ maxCollisionsPerEntity = getInt( "max-entity-collisions", 8 ); + log( "Max Entity Collisions: " + maxCollisionsPerEntity ); + } }