lmHighlights[m.start.x + sizeX * m.start.y] = true;
if (!m.end.noHighlight && V.OnBoard(m.end.x, m.end.y))
lmHighlights[m.end.x + sizeX * m.end.y] = true;
+ if (!!m.start.toplay)
+ // For Dice variant (at least?)
+ lmHighlights[m.start.toplay[0] + sizeX * m.start.toplay[1]] = true;
});
}
const showLight = (
const color = this.analyze ? this.vr.turn : this.userColor;
if (this.vr.canIplay(color, startSquare))
this.possibleMoves = this.vr.getPossibleMovesFrom(startSquare);
+ else return;
// For potential drag'n drop, remember start coordinates
// (to center the piece on mouse cursor)
const rect = parent.getBoundingClientRect();