SteamWar/BauSystem2.0
Archiviert
12
0

Fix offhand remove item
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
yoyosource 2022-07-21 17:25:07 +02:00
Ursprung e95b61e818
Commit 633112ffd1

Datei anzeigen

@ -98,7 +98,7 @@ public class TNTSimulatorListener implements Listener {
if (ItemUtils.isItem(e.getPlayer().getInventory().getItemInMainHand(), "simulator")) { if (ItemUtils.isItem(e.getPlayer().getInventory().getItemInMainHand(), "simulator")) {
simulatorShowHide(e.getPlayer(), i -> null, PlayerInventory::getItemInMainHand, e.getTo()); simulatorShowHide(e.getPlayer(), i -> null, PlayerInventory::getItemInMainHand, e.getTo());
TNTSimulator tntSimulator = SimulatorStorage.getSimulator(e.getPlayer().getInventory().getItemInOffHand()); TNTSimulator tntSimulator = SimulatorStorage.getSimulator(e.getPlayer().getInventory().getItemInOffHand());
if (tntSimulator != null) SimulatorPreviewStorage.hide(e.getPlayer()); if (tntSimulator == null) SimulatorPreviewStorage.hide(e.getPlayer());
} else { } else {
TNTSimulator tntSimulator = simulatorShowHide(e.getPlayer(), i -> null, PlayerInventory::getItemInOffHand, e.getTo()); TNTSimulator tntSimulator = simulatorShowHide(e.getPlayer(), i -> null, PlayerInventory::getItemInOffHand, e.getTo());
if (tntSimulator != null) SimulatorPreviewStorage.show(e.getPlayer(), tntSimulator); if (tntSimulator != null) SimulatorPreviewStorage.show(e.getPlayer(), tntSimulator);