diff --git a/src/at/pcgamingfreaks/Minepacks/Bukkit/Backpack.java b/src/at/pcgamingfreaks/Minepacks/Bukkit/Backpack.java index 9dfb905..33ee662 100644 --- a/src/at/pcgamingfreaks/Minepacks/Bukkit/Backpack.java +++ b/src/at/pcgamingfreaks/Minepacks/Bukkit/Backpack.java @@ -188,6 +188,8 @@ public List setSize(int newSize) { bp.setItem(i, itemStackArray[i]); } + setChanged(); + save(); // Make sure the new inventory is saved size = newSize; for(Entry e : opened.entrySet()) { diff --git a/src/at/pcgamingfreaks/Minepacks/Bukkit/Listener/DisableShulkerboxes.java b/src/at/pcgamingfreaks/Minepacks/Bukkit/Listener/DisableShulkerboxes.java index db0e28b..8afe5f8 100644 --- a/src/at/pcgamingfreaks/Minepacks/Bukkit/Listener/DisableShulkerboxes.java +++ b/src/at/pcgamingfreaks/Minepacks/Bukkit/Listener/DisableShulkerboxes.java @@ -61,7 +61,7 @@ public void onInventoryClick(InventoryClickEvent event) @EventHandler(ignoreCancelled = true) public void onInventoryOpen(InventoryOpenEvent event) { - if(event.getInventory().getHolder().getClass().getName().toLowerCase().contains("shulker")) + if(event.getInventory() != null && event.getInventory().getHolder() != null && event.getInventory().getHolder().getClass().getName().toLowerCase().contains("shulker")) { event.setCancelled(true); }