diff options
| author | Ian Gent | 2018-06-26 16:43:45 +0100 |
|---|---|---|
| committer | Ian Gent | 2018-06-26 16:43:45 +0100 |
| commit | 0798cfe1ecb92996ed7959383dcc4b8b0d51a1d9 (patch) | |
| tree | f6f6dbd927012de317feea6b2bb25d466cff1ac3 /src/main/game/global_cache.cpp | |
| parent | first R file (diff) | |
| parent | Merge pull request #71 from thecharlesblake/correct-klondike (diff) | |
| download | metasol-0798cfe1ecb92996ed7959383dcc4b8b0d51a1d9.tar.gz metasol-0798cfe1ecb92996ed7959383dcc4b8b0d51a1d9.zip | |
Merge branch ‘master’ of github.com:thecharlesblake/Solvitaire into ipg
Diffstat (limited to 'src/main/game/global_cache.cpp')
| -rw-r--r-- | src/main/game/global_cache.cpp | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/main/game/global_cache.cpp b/src/main/game/global_cache.cpp index db0c6de..f688c33 100644 --- a/src/main/game/global_cache.cpp +++ b/src/main/game/global_cache.cpp @@ -81,13 +81,7 @@ void cached_game_state::add_card(card c, const game_state& gs) { // If the game is a 'hole-based' game, or suit-reduction is on, reduces // the cached suit of the card where possible - bool is_suit_symmetry = gs.rules.hole; -#ifdef SUIT_REDUCTION_STREAMLINER - is_suit_symmetry = true; -#endif -#ifdef NO_SUIT_SYMMETRY - is_suit_symmetry = false; -#endif + bool is_suit_symmetry = gs.streamliners || gs.rules.hole; if (is_suit_symmetry) { switch (gs.rules.build_pol) { @@ -141,13 +135,7 @@ size_t hasher::hash_value(card const& c) const { // If the game is a 'hole-based' game, or suit-reduction is enabled, hash // the reduced suit - bool is_suit_symmetry = init_gs.rules.hole; -#ifdef SUIT_REDUCTION_STREAMLINER - is_suit_symmetry = true; -#endif -#ifdef NO_SUIT_SYMMETRY - is_suit_symmetry = false; -#endif + bool is_suit_symmetry = init_gs.streamliners || init_gs.rules.hole; uint8_t suit_val; if (is_suit_symmetry) { |
