PrintMove prints promotion as well | bench 4118297
This commit is contained in:
1 parent
30aaea5e03
commit
537139f5d0
1 file changed
+12
@@ -56,6 +56,18 @@ public:
|
|||||||
|
|
||||||
void PrintMove() {
|
void PrintMove() {
|
||||||
std::cout << squareCoords[MoveFrom()] << squareCoords[MoveTo()];
|
std::cout << squareCoords[MoveFrom()] << squareCoords[MoveTo()];
|
||||||
|
|
||||||
|
int flags = GetFlags();
|
||||||
|
|
||||||
|
if (flags == knightPromotion || flags == knightPromoCapture) {
|
||||||
|
std::cout << 'n';
|
||||||
|
} else if (flags == bishopPromotion || flags == bishopPromoCapture) {
|
||||||
|
std::cout << 'b';
|
||||||
|
} else if (flags == rookPromotion || flags == rookPromoCapture) {
|
||||||
|
std::cout << 'r';
|
||||||
|
} else if (flags == queenPromotion || flags == queenPromoCapture) {
|
||||||
|
std::cout << 'q';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
operator uint16_t() {
|
operator uint16_t() {
|
||||||
|
|||||||
Reference in new issue
Block a user