ImmersiveMC

ImmersiveMC

683k Downloads

[HIGH PRIORITY] DirtyTracker Conflicts with Cobblemon Healing Station (and Likely Other Block Entities)

hammy275 opened this issue ยท 0 comments

commented

When a block entity changes, including removal, a mixin (https://github.com/hammy275/immersive-mc/blob/1.20.x/common/src/main/java/com/hammy275/immersivemc/mixin/LevelMixin.java#L18-L25) gets the block entity and checks its type to determine if we should track it for dirtiness (for network syncing). When this happens, the block entity gets "revived", then next tick(?), gets marked for removal again, causing a cycle. I'm not sure why other block entities have seemingly tolerated this fine, but the healing station does not.

Honestly, I think by far the easiest and most reasonable solution is to just let anything marked dirty get added to the dirty tracker. This would be bad, but dirtiness is cleared at the end of each tick anyways, so the data doesn't linger for long. Combined with only so many things becoming dirty each tick, and this is a plenty good solution.