kayjaydee 1e47f4e846 refactor(03-06): remove debug logs + efficiency pass
Log cleanup:
- Drop redundant INFO "Gravity Flip enabled" in setup() (substantive version at
  start() remains as the single startup line).
- Drop INFO "debug enter/exit notifier ENABLED" (the notifier itself emits per
  region transition; extra startup noise not needed).
- Remove dead back-compat GravityApplier ctors that accepted an infoHandler
  Consumer (no callers post-03-06; debug logs already stripped).
- Clean stale javadoc referencing removed [DBG npc.woken]/[DBG npc.ctrlNull]
  one-shot logs.
- Also ship the pre-staged cleanup work: RegionEnterNotifier gated behind
  GRAVITYFLIP_DEBUG_NOTIFY env var, GravityApplier infoHandler field removed,
  tick logs stripped.

Efficiency:
- RegionVisualizer.resolveParticleId now memoises the requested->resolved
  mapping in a ConcurrentHashMap, eliminating the ParticleSystem.getAssetMap()
  lookup on every tick emission per region. Warn-once semantics preserved via
  warnedInvalidIds. Fail-open path (AssetMap unavailable in tests) intentionally
  does not populate the cache.
- Document in GravityApplier javadoc why Pass 1 + Pass 2 cannot be fused:
  restore requires the complete currentlyInRegion set before diffing against
  previouslyInverted.

Considered but not applied:
- ParticleEdgeEmitter.edgePoints caching per (box, density): throttled to
  >=100ms refresh and typical <20 regions => alloc pressure negligible;
  premature without measurement.
- Reusing RegionRegistry snapshot in RegionEnterNotifier: notifier is
  opt-in/off-by-default, so its independent ECS scan has zero prod cost.

Tests: ./gradlew clean build green, no test changes required.
2026-04-23 16:43:07 +02:00
S
Description
Gravity Flip lets you create anti-gravity regions on your Hytale server using a wand — no scripting, no file edits, no server restarts. Want to walk on the ceiling? Place two corners, name the region, and flip the world.
274 KiB
Languages
Java 100%