mirror of
https://github.com/GeorgH93/Minepacks.git
synced 2024-12-04 14:03:24 +01:00
Fix issues loading backpacks
This commit is contained in:
parent
83c1ca1cc0
commit
f7b51a3a28
@ -162,7 +162,7 @@ private void loadPlayer(final @NotNull MinepacksPlayerData player)
|
||||
public void loadBackpack(final @NotNull MinepacksPlayerData player)
|
||||
{
|
||||
player.setBackpackLoadingRequested(true);
|
||||
backend.loadPlayer(player);
|
||||
backend.loadBackpack(player);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
@ -77,6 +77,7 @@ public void setBackpack(final @NotNull Backpack backpack)
|
||||
{
|
||||
this.backpack = backpack;
|
||||
backpackLoadedQueue.forEach(backpackCallback -> backpackCallback.onResult(backpack));
|
||||
backpackLoadedQueue.clear();
|
||||
}
|
||||
|
||||
public void setLoaded(final @NotNull Object databaseKey, final long cooldown)
|
||||
@ -84,6 +85,7 @@ public void setLoaded(final @NotNull Object databaseKey, final long cooldown)
|
||||
this.databaseKey = databaseKey;
|
||||
this.cooldown = cooldown;
|
||||
playerLoadedQueue.forEach(loadedCallback -> loadedCallback.onResult(this));
|
||||
playerLoadedQueue.clear();
|
||||
}
|
||||
|
||||
public void setCooldownData(final long cooldown)
|
||||
|
Loading…
Reference in New Issue
Block a user