projects
/
vchess.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Attempt to clarify installation instructions a little
[vchess.git]
/
client
/
src
/
variants
/
Avalanche.js
diff --git
a/client/src/variants/Avalanche.js
b/client/src/variants/Avalanche.js
index
17e2138
..
db02459
100644
(file)
--- a/
client/src/variants/Avalanche.js
+++ b/
client/src/variants/Avalanche.js
@@
-104,7
+104,7
@@
export class AvalancheRules extends ChessRules {
vanish: [
new PiPo({ x: rank, y: file, c: color, p: V.PAWN })
],
vanish: [
new PiPo({ x: rank, y: file, c: color, p: V.PAWN })
],
- start: { x: 8, y: y },
+ start: { x: 8
+ (color == 'b' ? 1 : 0)
, y: y },
end: { x: rank, y: file }
});
}
end: { x: rank, y: file }
});
}
@@
-340,6
+340,7
@@
export class AvalancheRules extends ChessRules {
this.play(moves[3]); //HACK... 3 = queen index
const res = this.getComputerMove();
this.undo(moves[3]);
this.play(moves[3]); //HACK... 3 = queen index
const res = this.getComputerMove();
this.undo(moves[3]);
+ if (Array.isArray(res)) return [moves[3]].concat(res);
return [moves[3], res];
}
// subTurn == 1 (necessarily)
return [moves[3], res];
}
// subTurn == 1 (necessarily)