X-Git-Url: https://git.auder.net/?a=blobdiff_plain;f=public%2Fjavascripts%2Fcomponents%2Fgame.js;h=147aeafeeb76f066daf27878785b96d7102a96e4;hb=7d6b0773c093ad4347ff8b444236e7d89b06977e;hp=3eb27f27130689013d72437bca18b5c61b40d8bd;hpb=01ca2adce0ddcf246f184c6d19389262b0f5e6e5;p=vchess.git diff --git a/public/javascripts/components/game.js b/public/javascripts/components/game.js index 3eb27f27..147aeafe 100644 --- a/public/javascripts/components/game.js +++ b/public/javascripts/components/game.js @@ -668,7 +668,7 @@ Vue.component('my-game', { this.selectedPiece.style.display = "inline-block"; this.selectedPiece.style.zIndex = 3000; let startSquare = this.getSquareFromId(e.target.parentNode.id); - this.possibleMoves = this.vr.canIplay(this.mycolor,startSquare) + this.possibleMoves = this.mode!="idle" && this.vr.canIplay(this.mycolor,startSquare) ? this.vr.getPossibleMovesFrom(startSquare) : []; e.target.parentNode.appendChild(this.selectedPiece);