diff options
| author | 2015-03-31 23:53:25 +0200 | |
|---|---|---|
| committer | 2015-03-31 23:53:25 +0200 | |
| commit | 5bd5a8a07a900c013c120b4e228c766a84a05b09 (patch) | |
| tree | ba9b3fa5ce6e81ab8ecd2c66073fa1911e9b8568 /diceparser.h | |
| parent | 4c9a68db5423c5d798d178d4dafb5bf8e3228ed1 (diff) | |
| parent | a03f73495bc6ce71630129a92408a26f81ae301f (diff) | |
| download | OneRoll-5bd5a8a07a900c013c120b4e228c766a84a05b09.tar.gz OneRoll-5bd5a8a07a900c013c120b4e228c766a84a05b09.zip | |
Merge branch 'master' of github.com:obiwankennedy/DiceParser
Conflicts:
node/node.pri
Diffstat (limited to 'diceparser.h')
| -rw-r--r-- | diceparser.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/diceparser.h b/diceparser.h index 21a71a6..6dd2a10 100644 --- a/diceparser.h +++ b/diceparser.h @@ -39,12 +39,16 @@ class ExploseDiceNode; * * The grammar is something like this: * - * Command =: Expression | ScalarOperator Expression + * Line =: Command | Command;Command + * Command =: Expression | ScalarOperator Expression | ScalarOperator NodeAction Expression * Expression =: number | number Dice | Command - * Dice =: DiceOperator Number(faces) - * DiceOperator =: D + * Dice =: DiceOperator Number(faces) | DiceOperator List + * List =: [Word,Number,',']+ + * NodeAction =: @ + * DiceOperator =: [D,L] * ScalarOperator =: [x,-,*,x,/] * number =: [0-9]+ + * Word =: [A-z]+ * */ @@ -65,14 +69,13 @@ public: * @brief The DiceSymbol enum */ enum NodeAction {JumpBackward}; - - - /** * @brief The OptionOperator enum gathering all options availables for result. */ enum OptionOperator {KeepAndExplose,Keep,Reroll,Explosing,Sort,Count,RerollAndAdd}; + enum CommandOperator {}; + /** * @brief DiceParser default constructor */ @@ -211,7 +214,7 @@ private: QMap<QString,OptionOperator>* m_OptionOp; QMap<QString,NodeAction>* m_nodeActionMap; QMap<QString,QString>* m_aliasMap; - QList<QString>* m_commandList; + QStringList* m_commandList; QMap<ExecutionNode::ERROR_CODE,QString> m_errorMap; |