Xiangiqgame
AI engine for Xiangqi
Loading...
Searching...
No Matches
piecepoints Namespace Reference

Providing position-dependent values of pieces to objects in moveselection namespace. More...

Classes

class  BPOPointsEKeys
 Piece Points spec in "Base Points Offset" form with PieceType enum keys in member unordered_map objects for easy conversion to / from piecepoints::GamePointsArray_t form. More...
 
class  BPOPointsSKeys
 Piece Points spec in "Base Points Offset" form with string keys in member unordered_map objects for easy reading / writing data from / to .json files. More...
 
struct  PiecePositionPoints
 Holds a piecepoints::GamePointsArray_t of points values, and exposes a method for accessing element correspondig to specific gameboard::PieceType located at a specific gameboard::BoardSpace. More...
 
struct  PiecePositionPointsForConcepts
 Holds a piecepoints::GamePointsArray_t of points values, and exposes a method for accessing element correspondig to specific gameboard::PieceType located at a specific gameboard::BoardSpace. More...
 

Typedefs

typedef array< array< int, gameboard::kNumFiles >, gameboard::kNumRanksPiecePointsArray_t
 2-D array of points values for single piece at each position on a gameboard::GameBoard.board_map_.
 
typedef array< PiecePointsArray_t, gameboard::kNumPieceTypeValsTeamPointsArray_t
 
typedef unordered_map< gameboard::PieceType, PiecePointsArray_tTeamPointsEMap_t
 
typedef unordered_map< string, PiecePointsArray_tTeamPointsSMap_t
 
typedef array< TeamPointsArray_t, 2 > GamePointsArray_t
 
typedef unordered_map< gameboard::PieceColor, TeamPointsEMap_tGamePointsEMap_t
 
typedef unordered_map< string, TeamPointsSMap_tGamePointsSMap_t
 
typedef unordered_map< gameboard::PieceType, Points_tTeamBasePoints_t
 
typedef unordered_map< string, Points_tBasePointsSMap_t
 

Functions

size_t size_of_points_type ()
 
bool is_signed_points_type ()
 
bool operator== (const PiecePointsArray_t &a, const PiecePointsArray_t &b)
 
bool operator== (const TeamPointsSMap_t &a, const TeamPointsSMap_t &b)
 
bool operator== (GamePointsSMap_t &a, GamePointsSMap_t &b)
 

Variables

const string kICGABPOPath = utility_functs::get_data_file_abs_path("ICGA_2004_bpo.json")
 
const string kICGARawPath = utility_functs::get_data_file_abs_path("ICGA_2004_raw.json")
 
const string kRawSchemaPath
 
const string kBPOSchemaPath = utility_functs::get_data_file_abs_path("bpo_schema.json")
 

Detailed Description

Providing position-dependent values of pieces to objects in moveselection namespace.

Typedef Documentation

◆ BasePointsSMap_t

typedef unordered_map<string, Points_t> piecepoints::BasePointsSMap_t

Definition at line 72 of file piece_points_data_structs.hpp.

◆ GamePointsArray_t

◆ GamePointsEMap_t

◆ GamePointsSMap_t

typedef unordered_map<string, TeamPointsSMap_t> piecepoints::GamePointsSMap_t

Definition at line 58 of file piece_points_data_structs.hpp.

◆ PiecePointsArray_t

2-D array of points values for single piece at each position on a gameboard::GameBoard.board_map_.

Definition at line 22 of file piece_points_data_structs.hpp.

◆ TeamBasePoints_t

◆ TeamPointsArray_t

◆ TeamPointsEMap_t

◆ TeamPointsSMap_t

typedef unordered_map<string, PiecePointsArray_t> piecepoints::TeamPointsSMap_t

Definition at line 41 of file piece_points_data_structs.hpp.

Function Documentation

◆ is_signed_points_type()

bool piecepoints::is_signed_points_type ( )
inline

Definition at line 18 of file piece_points_data_structs.hpp.

◆ operator==() [1/3]

bool piecepoints::operator== ( const PiecePointsArray_t a,
const PiecePointsArray_t b 
)
inline

Definition at line 24 of file piece_points_data_structs.hpp.

◆ operator==() [2/3]

bool piecepoints::operator== ( const TeamPointsSMap_t a,
const TeamPointsSMap_t b 
)
inline

Definition at line 43 of file piece_points_data_structs.hpp.

◆ operator==() [3/3]

bool piecepoints::operator== ( GamePointsSMap_t a,
GamePointsSMap_t b 
)
inline

Definition at line 59 of file piece_points_data_structs.hpp.

◆ size_of_points_type()

size_t piecepoints::size_of_points_type ( )
inline

Definition at line 17 of file piece_points_data_structs.hpp.

Variable Documentation

◆ kBPOSchemaPath

const string piecepoints::kBPOSchemaPath = utility_functs::get_data_file_abs_path("bpo_schema.json")

Definition at line 82 of file base_position_offset.hpp.

◆ kICGABPOPath

const string piecepoints::kICGABPOPath = utility_functs::get_data_file_abs_path("ICGA_2004_bpo.json")

Definition at line 78 of file base_position_offset.hpp.

◆ kICGARawPath

const string piecepoints::kICGARawPath = utility_functs::get_data_file_abs_path("ICGA_2004_raw.json")

Definition at line 79 of file base_position_offset.hpp.

◆ kRawSchemaPath

const string piecepoints::kRawSchemaPath
Initial value:
=
utility_functs::get_data_file_abs_path("raw_points_schema.json")
const string get_data_file_abs_path(const std::string data_file)

Definition at line 80 of file base_position_offset.hpp.