aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/node/occurencecountnode.h
diff options
context:
space:
mode:
authorRenaud G <renaud@rolisteam.org>2019-07-10 11:55:14 +0200
committerRenaud G <renaud@rolisteam.org>2019-07-10 11:55:14 +0200
commit8e8384b27f83d0375d381a86622b0afd4c42eacb (patch)
tree0e3adae5dcbee0244e5b547dd6c618637ece10e4 /node/occurencecountnode.h
parent51f9064933ee08afeb774fe962617572a992d0c5 (diff)
downloadOneRoll-8e8384b27f83d0375d381a86622b0afd4c42eacb.tar.gz
OneRoll-8e8384b27f83d0375d381a86622b0afd4c42eacb.zip
Change behaviour of occurence count node.
Now it can generate a dice result.
Diffstat (limited to 'node/occurencecountnode.h')
-rw-r--r--node/occurencecountnode.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/node/occurencecountnode.h b/node/occurencecountnode.h
index 125f340..492b295 100644
--- a/node/occurencecountnode.h
+++ b/node/occurencecountnode.h
@@ -24,6 +24,7 @@
#include "validator.h"
class StringResult;
+class DiceResult;
class OccurenceCountNode : public ExecutionNode
{
public:
@@ -45,10 +46,15 @@ public:
void setValidator(Validator* validator);
private:
+ void runForStringResult(const std::map<qint64, qint64>& mapOccurence, QVector<qint64>& vec);
+ void runForDiceResult(const std::map<qint64, qint64>& mapOccurence);
+
+private:
qint64 m_width= 1;
qint64 m_height= 0;
Validator* m_validator= nullptr;
StringResult* m_stringResult= nullptr;
+ DiceResult* m_diceResult= nullptr;
};
#endif // OCCURENCECOUNTNODE_H