From e636a6ad5838e12962de3fad4bb835f0db0159f6 Mon Sep 17 00:00:00 2001 From: Daniel Mills Date: Thu, 5 Aug 2021 20:06:22 -0400 Subject: [PATCH] Docs --- .../volmit/iris/util/matter/slices/EntityMatter.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/main/java/com/volmit/iris/util/matter/slices/EntityMatter.java b/src/main/java/com/volmit/iris/util/matter/slices/EntityMatter.java index 3815c6701..f4601096a 100644 --- a/src/main/java/com/volmit/iris/util/matter/slices/EntityMatter.java +++ b/src/main/java/com/volmit/iris/util/matter/slices/EntityMatter.java @@ -75,6 +75,18 @@ public class EntityMatter extends RawMatter { super(width, height, depth, MatterEntityGroup.class); } + /** + * The readFrom is overridden only if W is a Bukkit World, instead of looping + * across every block position, we simply use getNearbyEntities and cache each + * block position with a list of entities within that block, and directly feed + * the reader with the entities we capture. + * @param w the world + * @param x the x offset + * @param y the y offset + * @param z the z offset + * @param the type + * @return true if we read + */ @Override public synchronized boolean readFrom(W w, int x, int y, int z) { if(!(w instanceof World))