Fixed bugs and oversights

This commit is contained in:
Bas de Jong
2025-10-07 22:39:47 +02:00
parent ed3cb902e4
commit 72e322675e
9 changed files with 14 additions and 20 deletions

View File

@@ -8,7 +8,7 @@ import org.toop.framework.networking.NetworkingClientManager;
import org.toop.framework.networking.NetworkingInitializationException;
public final class Main {
public static void main(String[] args) {
static void main(String[] args) {
initSystems();
App.run(args);
}

View File

@@ -1,5 +1,6 @@
package org.toop.app.layer.layers.game;
import java.util.Objects;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.atomic.AtomicBoolean;
@@ -153,6 +154,7 @@ public final class TicTacToeLayer extends Layer {
if (legalMove.position() == wants.position()
&& legalMove.value() == wants.value()) {
move = wants;
// TODO: maybe add break?
}
}
} catch (InterruptedException _) {
@@ -315,7 +317,7 @@ public final class TicTacToeLayer extends Layer {
ticTacToe.get(),
compurterDifficultyToDepth(10, information.computerDifficulty()[0]));
position = move.position();
position = Objects.requireNonNull(move).position();
}
new EventFlow()