mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-11 03:14:35 +02:00
Fix
This commit is contained in:
@@ -119,7 +119,8 @@ module.exports = class DomineeringCommand extends Command {
|
|||||||
for (let i = 0; i < board.length; i++) {
|
for (let i = 0; i < board.length; i++) {
|
||||||
for (let j = 0; j < board[i].length; j++) {
|
for (let j = 0; j < board[i].length; j++) {
|
||||||
if (board[i][j]) continue;
|
if (board[i][j]) continue;
|
||||||
if (!board[i + 1] || !board[i][j + 1]) continue;
|
if (userTurn && !board[i + 1]) continue;
|
||||||
|
if (!userTurn && !board[i][j + 1]) continue;
|
||||||
if (board[userTurn ? i + 1 : i][userTurn ? j : j + 1]) continue;
|
if (board[userTurn ? i + 1 : i][userTurn ? j : j + 1]) continue;
|
||||||
possibleMoves.push(`${i},${j}`);
|
possibleMoves.push(`${i},${j}`);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user