Another typo... getting late
[vchess.git] / client / src / variants / Otage.js
index 8497098..b3fabec 100644 (file)
@@ -381,12 +381,12 @@ export class OtageRules extends ChessRules {
         break;
       case V.KING:
         baseMoves = this.getSlideNJumpMoves(
-          sq,
+          [x, y],
           V.steps[V.ROOK].concat(V.steps[V.BISHOP]),
           "oneStep"
         );
         if (!noCastle && this.castleFlags[this.turn].some(v => v < V.size.y))
-          baseMoves = baseMoves.concat(this.getCastleMoves(sq));
+          baseMoves = baseMoves.concat(this.getCastleMoves([x, y]));
         break;
     }
     // When a pawn in an union reaches final rank with a non-standard