Score increments when the player places a tile, also increments without the visible delay.

This commit is contained in:
Woody Folsom
2012-04-29 15:39:47 -04:00
parent 20f172c95a
commit c06f7ab38e
2 changed files with 4 additions and 5 deletions

View File

@@ -150,7 +150,6 @@ public class Referee implements Runnable {
private void play() {
int plies = 0;
while (!isOver()) {
getScorePanel().updateScore(getPlayerScore());
if (board.isPlayerTurn()) {
boolean wasInterrupted = false;
while (!humanPlayer.isReady()) {
@@ -178,7 +177,7 @@ public class Referee implements Runnable {
} else {
Move mv = computerPlayer.getMove(board, getPlayerModel());
playToken(mv);
// This is the call that gets a prediction of a user's move.
// Some changes will probably be necessary to put it in the
// right place and also to get the node weights. But... all in
@@ -189,12 +188,12 @@ public class Referee implements Runnable {
// random, meaningless data.
// getPlayerModel().getOutputNodes(getBoardState(board));
}
getScorePanel().updateScore(getPlayerScore());
mf.updateMessage(getMessage());
boardPanel.updateIcons();
LOGGER.info("plies: " + plies++);
try {
Thread.sleep(1000L);
Thread.sleep(250L);
} catch (InterruptedException ie) {
System.out
.println("Interrupted while waiting for human view ply!");