Small TraceChange & Restart auf 3 Uhr
Dieser Commit ist enthalten in:
Ursprung
1b9afcd5da
Commit
758153f5b9
@ -115,34 +115,34 @@ public class BauSystem extends JavaPlugin implements Listener {
|
||||
Bukkit.getScheduler().scheduleSyncRepeatingTask(this, () -> {
|
||||
SimpleDateFormat df = new SimpleDateFormat("HH:mm:ss");
|
||||
Date d = new Date();
|
||||
if (df.format(d).equalsIgnoreCase("23:55:00")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:55:00")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 5 Minuten neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:00")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:00")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 1 Minute neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:30")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:30")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 30 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:50")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:50")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 10 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:55")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:55")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 5 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:56")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:56")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 4 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:57")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:57")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 3 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:58")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:58")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 2 Sekunden neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("23:59:59")) {
|
||||
if (df.format(d).equalsIgnoreCase("02:59:59")) {
|
||||
Bukkit.broadcastMessage(PREFIX + "Der Server startet in 1 Sekunde neu");
|
||||
}
|
||||
if (df.format(d).equalsIgnoreCase("00:00:00")) {
|
||||
if (df.format(d).equalsIgnoreCase("03:00:00")) {
|
||||
Bukkit.spigot().restart();
|
||||
}
|
||||
}, 20L, 20L);
|
||||
|
@ -68,6 +68,7 @@ public class CommandBau {
|
||||
p.sendMessage("§6/bau togglereplace §7- Darf ein Spieler in einer Region replacen");
|
||||
p.sendMessage("§6/bau togglechgm §7- Darf ein Spieler seinen Spielmodus ändern");
|
||||
p.sendMessage("§6/nv §7- Aktiviert/Deaktiviert Nachtsicht");
|
||||
p.sendMessage("§6/trace §7- Gibt einen Überblick über die Funktionen des TNT-Tracers");
|
||||
}
|
||||
|
||||
@Command(name = "bau.home", aliases = "gs.home", inGameOnly = true)
|
||||
|
@ -45,8 +45,10 @@ public class TNTTracer implements Listener, Runnable {
|
||||
|
||||
public void end(){
|
||||
stop();
|
||||
locations.clear();
|
||||
allTracer.remove(world);
|
||||
if(!printed){
|
||||
locations.clear();
|
||||
allTracer.remove(world);
|
||||
}
|
||||
}
|
||||
|
||||
public void show(){
|
||||
@ -74,6 +76,7 @@ public class TNTTracer implements Listener, Runnable {
|
||||
continue;
|
||||
b.setType(Material.AIR);
|
||||
}
|
||||
printed = false;
|
||||
end();
|
||||
}
|
||||
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren