We no longer look for leaves as logs are broken, instead we hook into the games block state changes and watch for a leave block updating
When the leave is updated, and it's now too far away from a log, it's added to a queue of blocks to break
When the next server tick happens, 5 items are taken from this list and broken.
This reduces overhead of scanning for leaves as well as making the leaf decay no longer be directly tied to the block down trees but does preserve the behaviour of not decaying user placed leaves.
The block decay queue is now stored in world data meaning if the game crashes softly or the user disconnects. The leaves will continued to decay when the world is reloaded.
Leaves are no longer broken as a "player" as the hook does not have a player in scope. This should fix more issues than it causes.
Мод Accelerated Decay ускоряет распад листвы в Майнкрафт. Листья исчезают мгновенно после сруба дерева - никаких задержек, минимум лага. Работает на Fabric и Forge.