Almost added TitanChess + EvolutionChess
[vchess.git] / client / src / variants / Shatranj.js
index 105331f..0569f71 100644 (file)
@@ -1,6 +1,7 @@
 import { ChessRules } from "@/base_rules";
 
 export class ShatranjRules extends ChessRules {
+
   static get HasFlags() {
     return false;
   }
@@ -9,6 +10,14 @@ export class ShatranjRules extends ChessRules {
     return false;
   }
 
+  static get Monochrome() {
+    return true;
+  }
+
+  static get Notoodark() {
+    return true;
+  }
+
   static get PawnSpecs() {
     return Object.assign(
       {},
@@ -20,6 +29,11 @@ export class ShatranjRules extends ChessRules {
     );
   }
 
+  getPpath(b) {
+    if (b[1] == 'b') return "Shatranj/" + b;
+    return b;
+  }
+
   static get ElephantSteps() {
     return [
       [-2, -2],
@@ -138,4 +152,5 @@ export class ShatranjRules extends ChessRules {
       k: 1000
     };
   }
+
 };