X-Git-Url: https://git.auder.net/?p=vchess.git;a=blobdiff_plain;f=client%2Fsrc%2Fvariants%2FMonster.js;h=cffc49e76fbbacd3ef9dc8472b6bebddda22455b;hp=177f71d14abbb8cabbc2487a53b7af17fa729af2;hb=472c0c4f5aa29d96e080873ebfce2a04f664d852;hpb=5e1bc6519d4c81aeac40aec7390c64c913cbf566 diff --git a/client/src/variants/Monster.js b/client/src/variants/Monster.js index 177f71d1..cffc49e7 100644 --- a/client/src/variants/Monster.js +++ b/client/src/variants/Monster.js @@ -105,10 +105,9 @@ export class MonsterRules extends ChessRules { // Definition of 'c' in base class doesn't work: const c = move.vanish[0].c; const piece = move.vanish[0].p; - if (piece == V.KING && move.appear.length > 0) { + if (piece == V.KING) { this.kingPos[c][0] = move.appear[0].x; this.kingPos[c][1] = move.appear[0].y; - return; } this.updateCastleFlags(move, piece); }