diff options
Diffstat (limited to 'src/common.hpp')
-rw-r--r-- | src/common.hpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/common.hpp b/src/common.hpp index 54f9804..d4cebf5 100644 --- a/src/common.hpp +++ b/src/common.hpp @@ -187,11 +187,23 @@ namespace game { class unit_t; + class roll_params_t { + public: + size_t count = 1, sides = 20, bonus = 0; + + roll_params_t(void) = default; + roll_params_t(size_t sides_); + roll_params_t(size_t count_, size_t sides_); + roll_params_t(size_t count_, size_t sides_, size_t bonus_); + }; + class state_t { std::unordered_set<unit_t*> units; std::unordered_set<unit_t*> selected_units; std::unordered_set<unit_t*> awake_units; + procgen::prng_t dice_prng; + public: world::world_t world; interface::state_t *interface; @@ -204,6 +216,8 @@ namespace game { // These are called by the interface. void select(rectf_t rect); void command(v2f_t x); + + size_t roll(roll_params_t *P); }; } |