#include <usiResponse.h>
Public Member Functions | |
UsiResponse (const UsiState &, bool new_move_probability, bool verbose) | |
~UsiResponse () | |
bool | hasImmediateResponse (const std::string &command, std::string &out) |
void | genmoveProbability (int limit, MoveLogProbVector &out) |
Private Member Functions | |
MoveVector | generateGoodMoves () |
void | genmoveProbability (int limit, std::string &out) |
void | genmove (std::string &out) |
void | csashow (const NumEffectState &state, std::string &out) |
void | csamove (const NumEffectState &state, const std::string &str, std::string &out) |
void | ki2moves (const NumEffectState ¤t, const std::string &moves_str, std::string &out) |
Convert a usi moves string to a ki2 (Kanji) moves string. | |
void | ki2currentinfo (const NumEffectState ¤t, std::string &out) |
Outputs the number of moves and the last move in the ki2 format. | |
void | isValidPosition (const std::string &line, std::string &out) |
Private Attributes | |
const UsiState & | usi_state |
const bool | new_move_probability |
const bool | verbose |
Definition at line 15 of file usiResponse.h.
osl::game_playing::UsiResponse::UsiResponse | ( | const UsiState & | u, |
bool | new_move_probability, | ||
bool | verbose | ||
) |
Definition at line 21 of file usiResponse.cc.
Definition at line 26 of file usiResponse.cc.
void osl::game_playing::UsiResponse::csamove | ( | const NumEffectState & | state, |
const std::string & | str, | ||
std::string & | out | ||
) | [private] |
Definition at line 120 of file usiResponse.cc.
References osl::record::csa::show(), and osl::record::csa::strToMove().
void osl::game_playing::UsiResponse::csashow | ( | const NumEffectState & | state, |
std::string & | out | ||
) | [private] |
Definition at line 111 of file usiResponse.cc.
osl::MoveVector osl::game_playing::UsiResponse::generateGoodMoves | ( | ) | [private] |
Definition at line 31 of file usiResponse.cc.
References osl::game_playing::GameState::generateNotLosingMoves(), osl::game_playing::GameState::pushMove(), osl::record::csa::show(), and verbose.
void osl::game_playing::UsiResponse::genmove | ( | std::string & | out | ) | [private] |
Definition at line 100 of file usiResponse.cc.
References moves, and osl::record::csa::show().
void osl::game_playing::UsiResponse::genmoveProbability | ( | int | limit, |
MoveLogProbVector & | out | ||
) |
Definition at line 49 of file usiResponse.cc.
References osl::alt(), feature_set(), osl::move_probability::StateInfo::findShortThreatmate(), osl::move_probability::StandardFeatureSet::generateLogProb(), osl::rating::FeatureSet::generateLogProb(), osl::rating::RatingEnv::history, osl::move_probability::StandardFeatureSet::instance(), osl::rating::StandardFeatureSet::instance(), limit, osl::rating::RatingEnv::make(), osl::MoveLogProb::move(), osl::game_playing::GameState::moveHistory(), moves, osl::progress::ml::NewProgress::progress16(), osl::game_playing::GameState::pushMove(), and osl::game_playing::GameState::state().
void osl::game_playing::UsiResponse::genmoveProbability | ( | int | limit, |
std::string & | out | ||
) | [private] |
Definition at line 86 of file usiResponse.cc.
References osl::MoveLogProb::logProb(), osl::MoveLogProb::move(), moves, and osl::record::csa::show().
bool osl::game_playing::UsiResponse::hasImmediateResponse | ( | const std::string & | command, |
std::string & | out | ||
) |
Definition at line 199 of file usiResponse.cc.
Referenced by usiMovesToKanji().
void osl::game_playing::UsiResponse::isValidPosition | ( | const std::string & | line, |
std::string & | out | ||
) | [private] |
Definition at line 182 of file usiResponse.cc.
References moves, and osl::record::usi::parse().
void osl::game_playing::UsiResponse::ki2currentinfo | ( | const NumEffectState & | current, |
std::string & | out | ||
) | [private] |
Outputs the number of moves and the last move in the ki2 format.
Definition at line 160 of file usiResponse.cc.
References osl::Move::isValid(), and osl::record::csa::show().
void osl::game_playing::UsiResponse::ki2moves | ( | const NumEffectState & | current, |
const std::string & | moves_str, | ||
std::string & | out | ||
) | [private] |
Convert a usi moves string to a ki2 (Kanji) moves string.
Definition at line 133 of file usiResponse.cc.
References moves, osl::record::csa::show(), and osl::record::csa::strToMove().
const bool osl::game_playing::UsiResponse::new_move_probability [private] |
Definition at line 18 of file usiResponse.h.
const UsiState& osl::game_playing::UsiResponse::usi_state [private] |
Definition at line 17 of file usiResponse.h.
const bool osl::game_playing::UsiResponse::verbose [private] |
Definition at line 18 of file usiResponse.h.