![]() |
Conquer Chess
Chess and Starcraft combined
|
#include <iosfwd>#include <vector>

Go to the source code of this file.
Enumerations | |
| enum class | piece_type { bishop , king , knight , pawn , queen , rook } |
| The type of chess piece. More... | |
Functions | |
| std::vector< piece_type > | get_all_piece_types () noexcept |
| Get all the piece types. | |
| int | get_piece_value (const piece_type type) |
| Get the value of the pieces. | |
| void | test_piece_type () |
| Test this class and its free functions. | |
| piece_type | to_piece_type (const char c) |
| Convert the PGN notation of a piece to its type, e.g. | |
| std::string | to_str (const piece_type type) noexcept |
| Convert a piece_type to a string. | |
| std::ostream & | operator<< (std::ostream &os, const piece_type type) noexcept |
|
strong |
|
noexcept |
Get all the piece types.
| int get_piece_value | ( | const piece_type | type | ) |
Get the value of the pieces.
A king has a value of zero, although in practice its value is infinite
|
noexcept |
| void test_piece_type | ( | ) |
Test this class and its free functions.
| piece_type to_piece_type | ( | const char | c | ) |
Convert the PGN notation of a piece to its type, e.g.
'N' becomes a knight
|
noexcept |
Convert a piece_type to a string.