Fix TNTSimulatorListener
Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
Ursprung
e0483beb54
Commit
649a25166f
@ -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;
|
||||||
}
|
}
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren