+
+// TODO: debug Hiddenqueen
+//game.fen = "rbnqbknr/pppptppp/8/8/8/8/TPPPPPPP/RBNQBKNR w 0 ahah -";
+//game.fenStart = "rbnqbknr/pppptppp/8/8/8/8/TPPPPPPP/RBNQBKNR w 0 ahah -";
+//game.mycolor = 'w';
+
+ if (!game.mycolor) game.mycolor = (Math.random() < 0.5 ? "w" : "b");
+ this.compWorker.postMessage(["init", game.fen]);
+ this.vr = new V(game.fen);
+ game.players = [{ name: "Computer" }, { name: "Computer" }];
+ if (this.gameInfo.mode == "versus")
+ game.players[game.mycolor == 'w' ? 0 : 1] = { name: "Myself" };
+ game.score = "*"; //finished games are removed
+ game.mode = this.gameInfo.mode;
+ this.currentUrl = document.location.href; //to avoid playing outside page
+ this.game = game;
+ this.$refs["basegame"].re_setVariables(game);
+ this.compWorker.postMessage(["init", game.fen]);
+ if (this.gameInfo.mode == "auto" || game.mycolor != this.vr.turn)
+ this.playComputerMove();