From: Benjamin Auder Date: Thu, 13 Dec 2018 18:33:30 +0000 (+0100) Subject: Ultima bug: mate in 1 does not mate... X-Git-Url: https://git.auder.net/js/current/app_dev.php/css/doc/%3C?a=commitdiff_plain;h=c364df7516985616b09ee9ec3c4671ed6fd3ef8b;p=vchess.git Ultima bug: mate in 1 does not mate... --- diff --git a/public/javascripts/components/game.js b/public/javascripts/components/game.js index deccd5da..202f542a 100644 --- a/public/javascripts/components/game.js +++ b/public/javascripts/components/game.js @@ -1014,7 +1014,7 @@ Vue.component('my-game', { this.endGame(this.mycolor=="w"?"0-1":"1-0"); }, newGame: function(mode, fenInit, color, oppId, moves, continuation) { - const fen = fenInit || VariantRules.GenRandInitFen(); + const fen = "3N1K2/2n2q2/P1R1kPnN/p3b1p1/b7/5Q2/4r3/8 0000";//fenInit || VariantRules.GenRandInitFen(); console.log(fen); //DEBUG if (mode=="human" && !oppId) { @@ -1072,7 +1072,7 @@ Vue.component('my-game', { } else if (mode == "computer") { - this.mycolor = Math.random() < 0.5 ? 'w' : 'b'; + this.mycolor = "w";//Math.random() < 0.5 ? 'w' : 'b'; if (this.mycolor == 'b') setTimeout(this.playComputerMove, 500); }