aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/node/rerolldicenode.h
diff options
context:
space:
mode:
authorRobin Moussu <robin.moussu+git@gmail.com>2018-05-26 20:08:08 +0200
committerobiwankennedy <renaud@rolisteam.org>2018-06-01 13:53:00 +0200
commit0a9202c3ef0d3255ae3d57d0df68f7232396b580 (patch)
tree870a7fbaa421da1ada3a6e30ecf17d5dbc69a73a /node/rerolldicenode.h
parent00b6a6a04b341d5a6332083425e3524349cef521 (diff)
downloadOneRoll-0a9202c3ef0d3255ae3d57d0df68f7232396b580.tar.gz
OneRoll-0a9202c3ef0d3255ae3d57d0df68f7232396b580.zip
add "R" (Reroll until) operator
Diffstat (limited to 'node/rerolldicenode.h')
-rw-r--r--node/rerolldicenode.h13
1 files changed, 5 insertions, 8 deletions
diff --git a/node/rerolldicenode.h b/node/rerolldicenode.h
index c999dda..8bef6dd 100644
--- a/node/rerolldicenode.h
+++ b/node/rerolldicenode.h
@@ -18,8 +18,9 @@ public:
enum ReRollMode {EQUAL,LESSER,GREATER};
/**
* @brief RerollDiceNode
+ * @param reroll If true reroll the dice only once, otherwise until the condition is false
*/
- RerollDiceNode();
+ RerollDiceNode(bool reroll, bool addingMode);
/**
* @brief ~RerollDiceNode
@@ -40,12 +41,6 @@ public:
* @return
*/
virtual QString toString(bool )const;
-
-
- /**
- * @brief setAddingMode
- */
- virtual void setAddingMode(bool);
/**
* @brief getPriority
* @return
@@ -63,9 +58,11 @@ public:
private:
DiceResult* m_diceResult = nullptr;
- bool m_adding;
Validator* m_validator = nullptr;
ExecutionNode* m_instruction = nullptr;
+
+ const bool m_reroll;
+ const bool m_adding;
};
#endif // REROLLDICENODE_H