Prevent playing on opponent's turn in Avalanche
[vchess.git] / client / src / variants / Avalanche.js
index edeb564..17e2138 100644 (file)
@@ -25,6 +25,7 @@ export class AvalancheRules extends ChessRules {
   }
 
   canIplay(side, [x, y]) {
+    if (side != this.turn) return false;
     if (this.subTurn == 0) return (x >= V.size.x);
     const c = this.getColor(x, y);
     return (