Removed loading widget from Server.java

This commit is contained in:
lieght
2025-11-30 17:55:52 +01:00
parent 12a20a224e
commit 3953762178

View File

@@ -76,9 +76,6 @@ public final class Server {
final int reconnectAttempts = 10; final int reconnectAttempts = 10;
LoadingWidget loading = new LoadingWidget(0, reconnectAttempts);
loading.show(Pos.CENTER);
var a = new EventFlow() var a = new EventFlow()
.addPostEvent(NetworkEvents.StartClient.class, .addPostEvent(NetworkEvents.StartClient.class,
new TournamentNetworkingClient(), new TournamentNetworkingClient(),
@@ -89,7 +86,6 @@ public final class Server {
a.unsubscribe("startclient"); a.unsubscribe("startclient");
loading.hide();
this.user = user; this.user = user;
clientId = e.clientId(); clientId = e.clientId();
@@ -101,11 +97,8 @@ public final class Server {
startPopulateScheduler(); startPopulateScheduler();
populateGameList(); populateGameList();
}, false, "startclient").listen(NetworkEvents.ConnectTry.class, e -> { }, false, "startclient").listen(NetworkEvents.ConnectTry.class, e -> {
Platform.runLater(() -> loading.setAmount(e.amount())); // Platform.runLater(() -> loading.setAmount(e.amount()));
}).postEvent(); }).postEvent();
new EventFlow().listen(this::handleReceivedChallenge)
.listen(this::handleMatchResponse);
} }
private void sendChallenge(String opponent) { private void sendChallenge(String opponent) {