projects
/
xogo.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Draft Diamond variant
[xogo.git]
/
variants
/
Checkless
/
class.js
diff --git
a/variants/Checkless/class.js
b/variants/Checkless/class.js
index
bc85184
..
0e24b77
100644
(file)
--- a/
variants/Checkless/class.js
+++ b/
variants/Checkless/class.js
@@
-24,7
+24,7
@@
export default class ChecklessRules extends ChessRules {
}
filterValid(moves) {
}
filterValid(moves) {
- fmoves = super.filterValid(moves);
+
const
fmoves = super.filterValid(moves);
// Filter out moves giving check but not checkmate
const color = this.turn;
const oppCol = C.GetOppTurn(color);
// Filter out moves giving check but not checkmate
const color = this.turn;
const oppCol = C.GetOppTurn(color);
@@
-35,7
+35,7
@@
export default class ChecklessRules extends ChessRules {
const res = this.trackKingWrap(m, oppKingPos, (oppKp) => {
return (
!this.underCheck(oppKp, [color]) ||
const res = this.trackKingWrap(m, oppKingPos, (oppKp) => {
return (
!this.underCheck(oppKp, [color]) ||
- this.atLeastOneMove_aux(oppKp, kingPos, oppCol, color)
+
!
this.atLeastOneMove_aux(oppKp, kingPos, oppCol, color)
);
});
this.undoOnBoard(m);
);
});
this.undoOnBoard(m);