SteamWar/BauSystem2.0
Archiviert
12
0

Fix TNTSimulatorListener

Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
yoyosource 2021-07-10 13:06:02 +02:00
Ursprung e0483beb54
Commit 649a25166f

Datei anzeigen

@ -104,7 +104,8 @@ public class TNTSimulatorListener implements Listener {
private void simulatorShowHide(Player player, Function<PlayerInventory, ItemStack> itemStackFunction, Location location) { private void simulatorShowHide(Player player, Function<PlayerInventory, ItemStack> itemStackFunction, Location location) {
TNTSimulator simulator = get(player); TNTSimulator simulator = get(player);
if (!itemStackFunction.apply(player.getInventory()).isSimilar(WAND)) { ItemStack itemStack = itemStackFunction.apply(player.getInventory());
if (itemStack == null || !itemStack.isSimilar(WAND)) {
simulator.hide(); simulator.hide();
return; return;
} }