aboutsummaryrefslogtreecommitdiff
path: root/src/main/game/sol_rules.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/game/sol_rules.h')
-rw-r--r--src/main/game/sol_rules.h24
1 files changed, 14 insertions, 10 deletions
diff --git a/src/main/game/sol_rules.h b/src/main/game/sol_rules.h
index 17dd74a..a2f8fe9 100644
--- a/src/main/game/sol_rules.h
+++ b/src/main/game/sol_rules.h
@@ -11,6 +11,8 @@
#include <boost/optional.hpp>
#include <rapidjson/document.h>
+#include "card.h"
+
class sol_rules {
public:
enum class valid_sol {
@@ -28,7 +30,8 @@ public:
DESCENDING,
ASCENDING,
BOTH,
- SINGLE_CARD
+ SINGLE_CARD,
+ ANY
};
enum class build_policy {
CLUBS,
@@ -37,24 +40,25 @@ public:
SPADES,
ANY_SUIT,
SAME_SUIT,
- RED_BLACK
+ RED_BLACK,
+ N_A
};
+ static bool is_suit(build_policy);
+ static card::suit_t suit_val(build_policy);
+
static const sol_rules from_preset(const std::string);
static const sol_rules from_file(const std::string);
- static bool is_suit(build_policy);
- static int suit_val(build_policy);
-
- unsigned int tableau_pile_count;
+ uint8_t tableau_pile_count;
build_order build_ord;
build_policy build_pol;
- unsigned int max_rank;
+ card::rank_t max_rank;
bool hole;
bool foundations;
- unsigned int cells;
- unsigned int reserve_size;
- unsigned int stock_size;
+ uint8_t cells;
+ uint8_t reserve_size;
+ uint8_t stock_size;
private:
static sol_rules get_default();