more debug checks: do not use tablebase lookup and therefore check tablebase consistency
This commit is contained in:
parent
88cfbe21f3
commit
27b8c08ed4
2 changed files with 3 additions and 0 deletions
|
@ -4,6 +4,7 @@ project(dynamic_program CXX)
|
|||
set(CMAKE_CXX_STANDARD 20)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wpedantic -Werror")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O3")
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DGAME_STATE_NO_TABLEBASE_LOOKUP")
|
||||
|
||||
include_directories(
|
||||
${PROJECT_SOURCE_DIR}/include
|
||||
|
|
|
@ -753,9 +753,11 @@ namespace Hanabi {
|
|||
if(_pace < 0 || _endgame_turns_left == 0) {
|
||||
return 0;
|
||||
}
|
||||
#ifndef GAME_STATE_NO_TABLEBASE_LOOKUP
|
||||
if (_position_tablebase.contains(id_of_state)) {
|
||||
return _position_tablebase[id_of_state];
|
||||
}
|
||||
#endif
|
||||
|
||||
// TODO: Have some endgame analysis here?
|
||||
|
||||
|
|
Loading…
Reference in a new issue