- // TODO: group multi-moves into an array, to deduce color from index
- // and not need this (also repeated in BaseGame::re_setVariables())
- let vr_tmp = new V(game.fenStart); //vr is already at end of game
- for (let i = 0; i < reformattedMoves.length; i++) {
- game.moves[i].color = vr_tmp.turn;
- vr_tmp.play(reformattedMoves[i]);
- }
- // Blue background on chat button if last chat message arrived after my last move.
+ // Did a chat message arrive after my last move?
+ let vr_tmp = new V(game.fen); //start from last position