SteamWar/BungeeCore
Archiviert
13
2

Add Softreload cancel
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
Chaoscaot 2023-04-06 17:07:16 +02:00
Ursprung 06d3aeb9d1
Commit 81dbcc691a
2 geänderte Dateien mit 11 neuen und 0 gelöschten Zeilen

Datei anzeigen

@ -28,6 +28,7 @@ import de.steamwar.bungeecore.listeners.ping.PingListener;
import de.steamwar.bungeecore.network.BungeeNetworkHandler; import de.steamwar.bungeecore.network.BungeeNetworkHandler;
import de.steamwar.bungeecore.network.NetworkReceiver; import de.steamwar.bungeecore.network.NetworkReceiver;
import de.steamwar.bungeecore.network.SWScriptSyntaxForwarder; import de.steamwar.bungeecore.network.SWScriptSyntaxForwarder;
import de.steamwar.bungeecore.util.SchematicSearch;
import de.steamwar.sql.Punishment; import de.steamwar.sql.Punishment;
import de.steamwar.sql.SteamwarUser; import de.steamwar.sql.SteamwarUser;
import de.steamwar.sql.UserElo; import de.steamwar.sql.UserElo;
@ -235,6 +236,7 @@ public class BungeeCore extends Plugin {
tablistManager.disable(); tablistManager.disable();
errorLogger.unregister(); errorLogger.unregister();
Statement.closeAll(); Statement.closeAll();
SchematicSearch.abortAll();
} }
public static BungeeCore get() { public static BungeeCore get() {

Datei anzeigen

@ -65,6 +65,15 @@ public class SchematicSearch {
} }
} }
public static void abortAll() {
synchronized (searchQueue) {
searchQueue.clear();
}
if(currentSearch != null) {
currentSearch.end();
}
}
private static List<String> constructArguments(SteamwarUser user, File pattern) { private static List<String> constructArguments(SteamwarUser user, File pattern) {
return Arrays.asList(searchBinary, "-T", "1", "-s", "-u", String.valueOf(user.getId()), "-o", "json:std", "-m", "50", pattern.getAbsolutePath()); return Arrays.asList(searchBinary, "-T", "1", "-s", "-u", String.valueOf(user.getId()), "-o", "json:std", "-m", "50", pattern.getAbsolutePath());
} }