A few fixes + draft Interweave and Takenmake. Only 1 1/2 variant to go now :)
[vchess.git] / client / src / components / BaseGame.vue
index fd26d87..ddfe1e7 100644 (file)
@@ -423,8 +423,7 @@ export default {
           const L = this.moves.length;
           if (!Array.isArray(this.moves[L-1]))
             this.$set(this.moves, L-1, [this.moves[L-1], smove]);
-          else
-            this.$set(this.moves, L-1, this.moves.concat([smove]));
+          else this.moves[L-1].push(smove);
         }
       };
       const playMove = () => {
@@ -533,6 +532,8 @@ export default {
       for (let i=move.length -1; i >= 0; i--) this.vr.undo(move[i]);
       this.moves.pop();
       this.cursor--;
+      // The board may still show the possible moves: (TODO: bad solution)
+      this.$refs["board"].resetCurrentAttempt();
       this.inMultimove = false;
     },
     cancelLastMove: function() {