Migrate BauSystem to the new TechHider and remove the legacy TechHider

The new TechHider registers a permanent global filter, so BauSystem now uses
a single BauTechHider that combines the hiding rules of the spectator
techhider, /techhider and /xray per player. To support the different
obfuscation blocks of these rules, ForPlayer now provides the obfuscation
block per position.

The ChunkHider now also checks single valued chunk sections, which were sent
unfiltered before, and recalculates their block count if they change.
Unhandled packet types are logged once; statistics, debug samples and ping
responses are passed through.

The legacy TechHider and its access widener entries are removed.
This commit is contained in:
2026-10-31 15:00:37 +01:00
parent 7d4252325a
commit ce2a23f4b8
16 changed files with 295 additions and 644 deletions
@@ -69,6 +69,10 @@ public final class HullRegion {
return contains(location.getBlockX(), location.getBlockY(), location.getBlockZ());
}
public boolean chunkOutside(int chunkX, int chunkZ) {
return chunkX < (minX >> 4) || chunkX > ((maxX - 1) >> 4) || chunkZ < (minZ >> 4) || chunkZ > ((maxZ - 1) >> 4);
}
/**
* @return the index of the block within a bitset of {@link #volume()} bits, only valid for contained blocks
*/