mirror of
https://github.com/sockspls/badfish
synced 2025-04-29 16:23:09 +00:00
Add function to get ply from position
It will be used by future patches. No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
9446dd6da3
commit
d81def4fa9
1 changed files with 6 additions and 1 deletions
|
@ -271,7 +271,8 @@ public:
|
||||||
bool opposite_colored_bishops() const;
|
bool opposite_colored_bishops() const;
|
||||||
bool has_pawn_on_7th(Color c) const;
|
bool has_pawn_on_7th(Color c) const;
|
||||||
|
|
||||||
// Reset the gamePly variable to 0
|
// Game ply information
|
||||||
|
int ply() const;
|
||||||
void reset_game_ply();
|
void reset_game_ply();
|
||||||
|
|
||||||
// Position consistency check, for debugging
|
// Position consistency check, for debugging
|
||||||
|
@ -556,4 +557,8 @@ inline PieceType Position::captured_piece() const {
|
||||||
return st->capture;
|
return st->capture;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline int Position::ply() const {
|
||||||
|
return st->gamePly;
|
||||||
|
}
|
||||||
|
|
||||||
#endif // !defined(POSITION_H_INCLUDED)
|
#endif // !defined(POSITION_H_INCLUDED)
|
||||||
|
|
Loading…
Add table
Reference in a new issue