|
|
@ -3838,7 +3838,7 @@ public class GenericFunctions { |
|
|
|
public static boolean giveItem(Player p, ItemStack... items) { |
|
|
|
public static boolean giveItem(Player p, ItemStack... items) { |
|
|
|
HashMap<Integer,ItemStack> remaining = p.getInventory().addItem(items); |
|
|
|
HashMap<Integer,ItemStack> remaining = p.getInventory().addItem(items); |
|
|
|
if (remaining.isEmpty()) { |
|
|
|
if (remaining.isEmpty()) { |
|
|
|
SoundUtils.playLocalSound(p, Sound.ENTITY_ITEM_PICKUP, 1.0f, 1.0f); |
|
|
|
SoundUtils.playGlobalSound(p.getLocation(), Sound.ENTITY_ITEM_PICKUP, 1.0f, 1.0f); |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
for (Integer i : remaining.keySet()) { |
|
|
|
for (Integer i : remaining.keySet()) { |
|
|
|