diff options
| author | 2025-02-09 06:05:05 +0100 | |
|---|---|---|
| committer | 2025-02-09 06:05:05 +0100 | |
| commit | 6fcb5ca46927f7baab744e117af9eb1ce5b74838 (patch) | |
| tree | 803b14b1315dfed095705d0c417b19c970541535 /src/libparser/include | |
| parent | b8486f92408afa1a0c71d3f62d93f49ac8bebc60 (diff) | |
| download | OneRoll-6fcb5ca46927f7baab744e117af9eb1ce5b74838.tar.gz OneRoll-6fcb5ca46927f7baab744e117af9eb1ce5b74838.zip | |
[Dice] add functions: floor, ceil, round
Diffstat (limited to 'src/libparser/include')
| -rw-r--r-- | src/libparser/include/diceparser/parsingtoolbox.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/libparser/include/diceparser/parsingtoolbox.h b/src/libparser/include/diceparser/parsingtoolbox.h index 8cd9c25..2700ae4 100644 --- a/src/libparser/include/diceparser/parsingtoolbox.h +++ b/src/libparser/include/diceparser/parsingtoolbox.h @@ -36,6 +36,7 @@ #include <diceparser/diceparser_global.h> class Range; class RepeaterNode; +class RoundNode; class DiceAlias; class ExplodeDiceNode; class SwitchCaseNode; @@ -92,7 +93,10 @@ public: enum Function { - REPEAT + REPEAT, + FLOOR, + CEIL, + ROUND }; enum OptionOperator { @@ -167,7 +171,8 @@ public: static void readSubtitutionParameters(SubtituteInfo& info, QString& rest); static bool readPainterParameter(PainterNode* painter, QString& str); static bool readComma(QString& str); - bool readReaperArguments(RepeaterNode* node, QString& source); + bool readRepeaterArguments(RepeaterNode* node, QString& source); + bool readRoundArguments(RoundNode* node, QString& source); bool readExpression(QString& str, ExecutionNode*& node); bool readInstructionOperator(QChar c); bool readNode(QString& str, ExecutionNode*& node); |