Some bugs fixes
[xogo.git] / variants / Benedict / class.js
index 68667e1..81fee87 100644 (file)
@@ -6,7 +6,6 @@ export default class BenedictRules extends ChessRules {
   static get Options() {
     return {
       select: C.Options.select,
-      check: [],
       styles: [
         "balance",
         "cylinder",
@@ -36,13 +35,13 @@ export default class BenedictRules extends ChessRules {
     const attacks = specs.attack || specs.moves;
     for (let a of attacks) {
       outerLoop: for (let step of a.steps) {
-        let [i, j] = [x + step[0], this.computeY(y + step[1])];
+        let [i, j] = [x + step[0], this.getY(y + step[1])];
         let nbSteps = 1;
         while (this.onBoard(i, j) && this.board[i][j] == "") {
           if (a.range <= nbSteps++)
             continue outerLoop;
           i += step[0];
-          j = this.computeY(j + step[1]);
+          j = this.getY(j + step[1]);
         }
         if (
           this.onBoard(i, j) && this.getColor(i, j) == oppCol &&