
PacketGiveRewards modifies the world off of the main thread
Aaron1011 opened this issue ยท 0 comments
The handler for PacketGiveRewards modifies Minecraft game objects (modifiying players and executing commands ) directly from a netty thread. Since none of the core Minecraft objects are thread-safe, this can easily lead to world corruption.
Instead, PacketGiveRewards
should create a scheduled task (via MinecraftServer#addScheduledTask
, and perform all of its actions from within that task.