Bug fix — Watchdog crash (ItemStackManager.java):
- processAutoClear and forceClear were calling item.discard() while iterating level.getAllEntities() (a live iterable), causing a
ConcurrentModificationException that froze the server thread. Both methods now collect entities into a toRemove list first, then discard after iteration.
Feature — Mob nametag visibility distance (3 files):
- ModConfig.java: Added mobNametagVisibleDistance (default 0 = always visible, like current behavior). Set it to e.g. 32 to only show nametags within 32
blocks.
- MobStackManager.java:
- updateNametag no longer forces setCustomNameVisible(true) when distance mode is active
- New updateNametagVisibility(server) method checks each stacked mob against all players in the level and toggles visibility based on squared distance
- CobbleStackerMod.java: Calls updateNametagVisibility every 10 ticks (0.5s) when distance mode is enabled
Developer information
Projects on Modrinth are automatically available through a Maven repository for use with JVM build tools such as Gradle.
maven { name = "Modrinth"; url = "https://api.modrinth.com/maven" }