X-Git-Url: https://git.auder.net/?a=blobdiff_plain;f=client%2Fsrc%2Fviews%2FGame.vue;h=919a7ebca986bd7edd2dd87ed5a5ed713863539d;hb=90df90bca1a993930a0e1a07a1b4990dd538c6e2;hp=45410317837291da8917f5fbbeb1737c7e5d3acf;hpb=5b3d4006a8529aa90ee52096d5229d5dbdbd110f;p=vchess.git diff --git a/client/src/views/Game.vue b/client/src/views/Game.vue index 45410317..919a7ebc 100644 --- a/client/src/views/Game.vue +++ b/client/src/views/Game.vue @@ -252,9 +252,6 @@ export default { }, // NOTE: some redundant code with Hall.vue (mostly related to people array) created: function() { - if (this.$route.query["focus"] === "false") - // Focus explicitely set to false from Hall (live game) - this.focus = false; this.atCreation(); }, mounted: function() { @@ -749,6 +746,9 @@ export default { if (!this.game || !this.game.moves) this.lastateAsked = true; else this.sendLastate(data.from); break; + // TODO: possible bad scenario: reload page while oppponent sends a + // move => get both lastate and newmove, process both, add move twice. + // Confirm scenario? Fix? case "lastate": { // Got opponent infos about last move this.gotLastate = true; @@ -1054,7 +1054,7 @@ export default { let gameInfo = { id: getRandString(), //ignored if corr fen: V.GenRandInitFen(this.game.randomness), - players: this.game.players.reverse(), + players: [this.game.players[1], this.game.players[0]], vid: this.game.vid, cadence: this.game.cadence };