From: Benjamin Auder Date: Mon, 2 May 2022 12:42:05 +0000 (+0200) Subject: Fix Teleport bug on subturn 2 X-Git-Url: https://git.auder.net/doc/html/pieces/img/config.php?a=commitdiff_plain;h=8b301184ec7b90b7595f030457d5d2d38a44bcbc;p=xogo.git Fix Teleport bug on subturn 2 --- diff --git a/base_rules.js b/base_rules.js index 5d91c72..2b2ecfa 100644 --- a/base_rules.js +++ b/base_rules.js @@ -1238,6 +1238,8 @@ export default class ChessRules { // All possible moves from selected square getPotentialMovesFrom(sq, color) { + if (this.subTurnTeleport == 2) + return []; if (typeof sq[0] == "string") return this.getDropMovesFrom(sq); if (this.isImmobilized(sq))