Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
Ursprung
873b97f70d
Commit
161341da72
@ -100,6 +100,11 @@ public class TNTSimulator {
|
||||
simulator.hide();
|
||||
}
|
||||
|
||||
public void remove() {
|
||||
TNTSimulator simulator = TNT_SIMULATOR_MAP.remove(player);
|
||||
simulator.hide();
|
||||
}
|
||||
|
||||
private final Set<TNTSpawn> spawns = new HashSet<>();
|
||||
private final Player player;
|
||||
|
||||
@ -430,7 +435,7 @@ public class TNTSimulator {
|
||||
|
||||
// Change TickOffset
|
||||
swInventory.setItem(2, new SWItem(SWItem.getDye(10), "§7+1", Arrays.asList("§eShift §7Click für §e+5"), false, clickType -> {
|
||||
setTickOffset(count + (clickType.isShiftClick() ? 5 : 1));
|
||||
setTickOffset(tickOffset + (clickType.isShiftClick() ? 5 : 1));
|
||||
editTNT();
|
||||
}));
|
||||
SWItem tickItem = new SWItem(SWItem.getMaterial("DIODE"), "§7Tick §8- §e" + tickOffset, LORE, false, clickType -> changeCount(player, "Tick Offset", tickOffset, tick -> {
|
||||
@ -440,7 +445,7 @@ public class TNTSimulator {
|
||||
tickItem.getItemStack().setAmount(Math.max(tickOffset, 1));
|
||||
swInventory.setItem(11, tickItem);
|
||||
swInventory.setItem(20, new SWItem(SWItem.getDye(1), "§7-1", Arrays.asList("§eShift §7Click für §e-5"), false, clickType -> {
|
||||
setTickOffset(count - (clickType.isShiftClick() ? 5 : 1));
|
||||
setTickOffset(tickOffset - (clickType.isShiftClick() ? 5 : 1));
|
||||
editTNT();
|
||||
}));
|
||||
|
||||
|
@ -119,7 +119,6 @@ public class TNTSimulatorListener implements Listener, Disable {
|
||||
if (event.getItem() == null || !event.getItem().isSimilar(WAND)) {
|
||||
return;
|
||||
}
|
||||
System.out.println(event);
|
||||
|
||||
event.setCancelled(true);
|
||||
if (!permissionCheck(event.getPlayer())) {
|
||||
@ -142,7 +141,8 @@ public class TNTSimulatorListener implements Listener, Disable {
|
||||
|
||||
@EventHandler
|
||||
public void onPlayerQuit(PlayerQuitEvent event) {
|
||||
get(event.getPlayer()).saveAndDelete();
|
||||
get(event.getPlayer()).save();
|
||||
get(event.getPlayer()).remove();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren