File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed
Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -155,20 +155,21 @@ void handleGame(GameInfo game) {
155155 Board board = Board .fromFEN (fenAtGameStart );
156156 if (moves > 1 ) board = board .play (String .join (" " , moveList .subList (0 , moves -1 )));
157157 String lastMove = moveList .getLast ();
158- String lastMoveSAN = board .toSAN (lastMove );
158+
159+ String infoBeforeMove = "%s (%s) played (%s - %s)" .formatted (
160+ lastMove ,
161+ board .toSAN (lastMove ),
162+ white + (board .whiteToMove () ? "*" : "" ),
163+ black + (board .blackToMove () ? "*" : "" ));
159164
160165 board = board .play (lastMove );
161166
162- LOGGER .info ("%s\n %s" .formatted (
163- "%s (%s) played (%s - %s)" .formatted (
164- lastMove ,
165- lastMoveSAN ,
166- white + (board .whiteToMove () ? "*" : "" ),
167- black + (board .blackToMove () ? "*" : "" )),
168- "%s %s %s" .formatted (
169- board .toFEN (),
170- board .gameState (),
171- state .status ())));
167+ String infoAfterMove = "%s %s %s" .formatted (
168+ board .toFEN (),
169+ board .gameState (),
170+ state .status ());
171+
172+ LOGGER .info ("%s\n %s" .formatted (infoBeforeMove , infoAfterMove ));
172173 }
173174
174175 if (state .status ().ordinal () > Status .started .ordinal ()) {
You can’t perform that action at this time.
0 commit comments