- let noCaptures = this.getSlideNJumpMoves(
- x, y, c, VariantRules.steps[VariantRules.QUEEN], "oneStep");
- let captures = this.findCaptures(x, y, c);
-
- let moves = noCaptures
- .concat(captures)
- .concat(this.getCastleMoves(x, y, c));
-
- return moves;
+ let noCaptures = this.getSlideNJumpMoves(sq,
+ V.steps[V.ROOK].concat(V.steps[V.BISHOP]), "oneStep");
+ let captures = this.findCaptures(sq);
+ return noCaptures.concat(captures).concat(this.getCastleMoves(sq));