+ buildMoveStack(move, r) {
+ const color = this.turn;
+ if (
+ move.appear.length > 0 &&
+ move.appear[0].p == 'p' &&
+ (
+ (color == 'w' && move.end.x == 0) ||
+ (color == 'b' && move.end.x == this.size.x - 1)
+ )
+ ) {
+ // "Forgotten" promotion, which occurred after some effect
+ let moves = super.pawnPostProcess([move], color, C.GetOppCol(color));
+ super.showChoices(moves, r);
+ }
+ else
+ super.buildMoveStack(move, r);
+ }
+