From e93bea7fb99d4fbcad7a62aeeaee62cb135fa5bf Mon Sep 17 00:00:00 2001 From: xGinko Date: Thu, 29 Feb 2024 21:35:50 +0100 Subject: [PATCH] iterate over chunkentities in scheduler here --- .../modules/lagpreventions/FallingBlockStasis.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AnarchyExploitFixesFolia/src/main/java/me/moomoo/anarchyexploitfixes/modules/lagpreventions/FallingBlockStasis.java b/AnarchyExploitFixesFolia/src/main/java/me/moomoo/anarchyexploitfixes/modules/lagpreventions/FallingBlockStasis.java index ea9e747ea..0ee3cc283 100755 --- a/AnarchyExploitFixesFolia/src/main/java/me/moomoo/anarchyexploitfixes/modules/lagpreventions/FallingBlockStasis.java +++ b/AnarchyExploitFixesFolia/src/main/java/me/moomoo/anarchyexploitfixes/modules/lagpreventions/FallingBlockStasis.java @@ -64,7 +64,7 @@ private void run() { for (World world : plugin.getServer().getWorlds()) { for (Chunk chunk : world.getLoadedChunks()) { plugin.getServer().getRegionScheduler().run(plugin, world, chunk.getX(), chunk.getZ(), checkChunk -> { - for (Entity entity : world.getEntities()) { + for (Entity entity : chunk.getEntities()) { entity.getScheduler().run(plugin, checkEntity -> { if (entity.getType() == EntityType.FALLING_BLOCK && entity.getTicksLived() > max_alive_time) { entity.remove();