GTNewHorizons / Applied-Energistics-2-Unofficial

Unofficial AE2 for 1.7.10 which is still supported,which is like the extraterrestrial technology.
GNU Lesser General Public License v3.0
42 stars 97 forks source link

Allow crafting notifications to be sent on next player login #586

Closed OneEyeMaker closed 1 week ago

OneEyeMaker commented 2 weeks ago

Currently crafting notifications are only sent to players that are online. If the player starts a long craft, follows it and leaves server then one will not be notified if craft finishes while the player is offline. This PR introduces logic for storing such notifications and sending ones when the player logs in next time.

Question

This feature requires that the instance of CraftingCPUCluster is registered as event handler. This should happen on server start and when multiblock is (re-)assembled. The instance should also be properly unregistered to prevent flooding event bus with dead instances. Is there better place in code to register and unregister event handler?