fix: ensure mask is initialised upon visiting a point in BreadthFirstSearch (#2314)

fix: ensure mask is initialised upon visiting a point in BreadFirstSearch
This commit is contained in:
Jordan 2023-06-22 20:32:54 +01:00 committed by GitHub
parent d961aa91bc
commit 9f0a0dbd35
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -229,6 +229,7 @@ public abstract class BreadthFirstSearch implements Operation {
*/
public void visit(BlockVector3 position) {
if (!visited.contains(position)) {
isVisitable(position, position); // Ignore this, just to initialize mask on this point
queue.add(position);
visited.add(position);
}