Improved handling of async tasks (autosave, on server shutdown)

This commit is contained in:
Jules 2024-02-21 13:11:23 +01:00
parent 1e370864cd
commit 5e466dd8c2

View File

@ -280,9 +280,8 @@ public class MMOCore extends MMOPlugin {
for (Guild guild : dataProvider.getGuildManager().getAll())
dataProvider.getGuildManager().save(guild);
// Close MySQL data provider (memory leaks)
playerDataManager.saveAll(false);
playerDataManager.getDataHandler().close();
// Close player data manager
playerDataManager.close();
// Reset active blocks
mineManager.resetRemainingBlocks();