mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-04 12:06:41 +00:00
schem list is still broken
clickEvent and hoverEvent don't seem to work, I'm probably doing something wrong
This commit is contained in:
@ -670,7 +670,7 @@ public class CuboidRegion extends AbstractRegion implements FlatRegion {
|
||||
}
|
||||
|
||||
@Override
|
||||
public IChunkSet processBatch(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
public IChunkSet processSet(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
int bx = chunk.getX() << 4;
|
||||
int bz = chunk.getZ() << 4;
|
||||
int tx = bx + 15;
|
||||
|
@ -265,7 +265,17 @@ public interface Region extends Iterable<BlockVector3>, Cloneable, IBatchProcess
|
||||
contains(tx, ty, tz);
|
||||
}
|
||||
|
||||
default IChunkSet processBatch(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
default boolean containsChunk(int chunkX, int chunkZ) {
|
||||
int bx = chunkX << 4;
|
||||
int bz = chunkZ << 4;
|
||||
int tx = bx + 15;
|
||||
int tz = bz + 15;
|
||||
BlockVector3 min = getMinimumPoint();
|
||||
BlockVector3 max = getMaximumPoint();
|
||||
return tx >= min.getX() && bx <= max.getX() && tx >= min.getZ() && bx <= max.getZ();
|
||||
}
|
||||
|
||||
default IChunkSet processSet(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
int bx = chunk.getX() << 4;
|
||||
int bz = chunk.getZ() << 4;
|
||||
int tx = bx + 15;
|
||||
|
@ -155,7 +155,7 @@ public class RegionIntersection extends AbstractRegion {
|
||||
}
|
||||
|
||||
@Override
|
||||
public IChunkSet processBatch(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
public IChunkSet processSet(IChunk chunk, IChunkGet get, IChunkSet set) {
|
||||
int bx = chunk.getX() << 4;
|
||||
int bz = chunk.getZ() << 4;
|
||||
int tx = bx + 15;
|
||||
@ -164,7 +164,7 @@ public class RegionIntersection extends AbstractRegion {
|
||||
BlockVector3 regMin = region.getMinimumPoint();
|
||||
BlockVector3 regMax = region.getMaximumPoint();
|
||||
if (tx >= regMin.getX() && bx <= regMax.getX() && tz >= regMin.getZ() && bz <= regMax.getZ()) {
|
||||
return region.processBatch(chunk, get, set);
|
||||
return region.processSet(chunk, get, set);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
Reference in New Issue
Block a user