diff options
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; |