New method getCurrentMoveIndex in ChessEngine

PGN
Justin 2025-06-22 01:31:18 +02:00
parent 745bf05fd3
commit 572e7b1131
1 changed files with 2 additions and 0 deletions

View File

@ -102,6 +102,8 @@ public class ChessEngine {
currentMoveIndex = idx;
}
public int getCurrentMoveIndex() { return currentMoveIndex; }
private PieceDTO convertPieceToDTO(Piece piece) {
if (piece == null || piece.equals(Piece.NONE)) return null;
String color = piece.name().startsWith("WHITE") ? "WHITE" : "BLACK";