This commit is contained in:
GeorgH93 2020-01-26 01:06:25 +01:00
parent 46672c44f1
commit 643dbacc63
No known key found for this signature in database
GPG Key ID: D1630D37F9E4B3C8

View File

@ -129,8 +129,7 @@ public Backpack(OfflinePlayer owner, ItemStack[] backpack, int ID)
Minepacks.getInstance().getLogger().warning(owner.getName() + "'s backpack has to many items.");
if(owner.isOnline())
{
owner.getPlayer().getWorld().dropItemNaturally(owner.getPlayer().getLocation(), stack);
//Owner is online!
Bukkit.getScheduler().runTask(Minepacks.getInstance(), () -> owner.getPlayer().getWorld().dropItemNaturally(owner.getPlayer().getLocation(), stack));
}
else throw new RuntimeException("Backpack to big for MC 1.14 and up!");
}