From: Fabian Fichter Date: Sat, 6 Oct 2018 15:48:45 +0000 (+0200) Subject: Support Janus and Embassy chess X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=d4622058e47f7eb90a41b998717f0723c87a4c6e;p=fairystockfish.git Support Janus and Embassy chess No functional change for other variants. --- diff --git a/src/variant.cpp b/src/variant.cpp index 0d2325b..227868f 100644 --- a/src/variant.cpp +++ b/src/variant.cpp @@ -477,6 +477,29 @@ void VariantMap::init() { v->promotionPieceTypes = {ARCHBISHOP, CHANCELLOR, QUEEN, ROOK, BISHOP, KNIGHT}; return v; } (); + const Variant* janus = [&]{ + Variant* v = new Variant(); + v->maxRank = RANK_8; + v->maxFile = FILE_J; + v->castlingKingsideFile = FILE_I; + v->castlingQueensideFile = FILE_B; + v->add_piece(ARCHBISHOP, 'j'); + v->startFen = "rjnbkqbnjr/pppppppppp/10/10/10/10/PPPPPPPPPP/RJNBKQBNJR w KQkq - 0 1"; + v->promotionPieceTypes = {ARCHBISHOP, QUEEN, ROOK, BISHOP, KNIGHT}; + return v; + } (); + const Variant* embassy = [&]{ + Variant* v = new Variant(); + v->maxRank = RANK_8; + v->maxFile = FILE_J; + v->castlingKingsideFile = FILE_H; + v->castlingQueensideFile = FILE_B; + v->add_piece(ARCHBISHOP, 'a'); + v->add_piece(CHANCELLOR, 'c'); + v->startFen = "rnbqkcabnr/pppppppppp/10/10/10/10/PPPPPPPPPP/RNBQKCABNR w KQkq - 0 1"; + v->promotionPieceTypes = {ARCHBISHOP, CHANCELLOR, QUEEN, ROOK, BISHOP, KNIGHT}; + return v; + } (); #endif // Add to UCI_Variant option @@ -517,6 +540,8 @@ void VariantMap::init() { #ifdef LARGEBOARDS add("shogi", shogi); add("capablanca", capablanca); + add("janus", janus); + add("embassy", embassy); #endif }