cursor: -1, //index of the move just played
lastMove: null,
firstMoveNumber: 0, //for printing
- incheck: [] //for Board
+ incheck: [], //for Board
+ V: null // TODO: need "local" V to trigger re-computation of computed properties ?
+ // --> le passer depuis CompGame ou Game comme une property ?!
};
},
watch: {
// game initial FEN changes when a new game starts
+
+ // TODO: this watcher is obsolete ?
+
"game.fenStart": function() {
this.re_setVariables();
},
this.vr.re_init(this.moves[index].fen);
this.cursor = index;
this.lastMove = this.moves[index];
+ this.incheck = this.vr.getCheckSquares(this.vr.turn);
},
gotoBegin: function() {
if (this.cursor == -1) return;
this.cursor = -1;
this.lastMove = null;
}
+ this.incheck = this.vr.getCheckSquares(this.vr.turn);
},
gotoEnd: function() {
if (this.cursor == this.moves.length - 1) return;