diff options
| author | 2026-03-15 11:42:31 +0100 | |
|---|---|---|
| committer | 2026-03-15 10:57:32 +0000 | |
| commit | 6a91d28cf161e5a121d7bc09453e23455a109cbb (patch) | |
| tree | b69f9c82098dd52863c3d22fc52953eb432bc4c7 /src/libparser/node/dicerollernode.cpp | |
| parent | ef1e7c6d4244f60094d2c703324f0490320277af (diff) | |
| download | OneRoll-6a91d28cf161e5a121d7bc09453e23455a109cbb.tar.gz OneRoll-6a91d28cf161e5a121d7bc09453e23455a109cbb.zip | |
[tree]: improve tree generation
Diffstat (limited to 'src/libparser/node/dicerollernode.cpp')
| -rw-r--r-- | src/libparser/node/dicerollernode.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/libparser/node/dicerollernode.cpp b/src/libparser/node/dicerollernode.cpp index 8ef0164..f3e0887 100644 --- a/src/libparser/node/dicerollernode.cpp +++ b/src/libparser/node/dicerollernode.cpp @@ -66,16 +66,10 @@ std::pair<qint64, qint64> DiceRollerNode::getRange() const { return std::make_pair(m_min, m_max); } -QString DiceRollerNode::toString(bool wl) const +QString DiceRollerNode::toString(bool withlabel) const { - if(wl) - { - return QString("%1 [label=\"DiceRollerNode faces: %2\"]").arg(m_id).arg(getFaces()); - } - else - { - return m_id; - } + return withlabel ? QString("%1 [label=\"DiceRollerNode faces: %2\"]").arg(m_id).arg(getFaces()) : + ExecutionNode::toString(withlabel); } qint64 DiceRollerNode::getPriority() const { |