Dieser Commit ist enthalten in:
Ursprung
f624d2893d
Commit
badb5e5e1e
@ -36,14 +36,15 @@ public class SchematicSearch {
|
|||||||
private static void startQueueWatchdog() {
|
private static void startQueueWatchdog() {
|
||||||
watchdog = BungeeCore.get().getProxy().getScheduler().schedule(BungeeCore.get(), () -> {
|
watchdog = BungeeCore.get().getProxy().getScheduler().schedule(BungeeCore.get(), () -> {
|
||||||
synchronized (searchQueue) {
|
synchronized (searchQueue) {
|
||||||
|
if(searchQueue.isEmpty()) {
|
||||||
|
watchdog.cancel();
|
||||||
|
watchdog = null;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if(currentSearch == null) {
|
if(currentSearch == null) {
|
||||||
if(!searchQueue.isEmpty()) {
|
currentSearch = searchQueue.remove(0);
|
||||||
currentSearch = searchQueue.remove(0);
|
currentSearch.start();
|
||||||
currentSearch.start();
|
|
||||||
} else {
|
|
||||||
watchdog.cancel();
|
|
||||||
watchdog = null;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}, 0, 1, TimeUnit.SECONDS);
|
}, 0, 1, TimeUnit.SECONDS);
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren