diff options
| author | 2016-03-22 19:27:45 +0100 | |
|---|---|---|
| committer | 2016-03-22 19:27:45 +0100 | |
| commit | d466a529fe2ed5c09c2353c67c82df5c83d831cf (patch) | |
| tree | 6807e3729cf4eff1c750e5de04113af4809059bb /node/mergenode.cpp | |
| parent | 37320ce7aa23c52f950a97c756a2d9c618467d1d (diff) | |
| download | OneRoll-d466a529fe2ed5c09c2353c67c82df5c83d831cf.tar.gz OneRoll-d466a529fe2ed5c09c2353c67c82df5c83d831cf.zip | |
fix cpp check
Diffstat (limited to 'node/mergenode.cpp')
| -rw-r--r-- | node/mergenode.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/node/mergenode.cpp b/node/mergenode.cpp index 5145bc8..7f3bec0 100644 --- a/node/mergenode.cpp +++ b/node/mergenode.cpp @@ -32,26 +32,26 @@ void MergeNode::run(ExecutionNode* previous) if(NULL!=previous) { m_result->setPrevious(previous->getResult()); - } - Result* tmpResult = previous->getResult(); - while(NULL!=tmpResult) - { - DiceResult* dice = dynamic_cast<DiceResult*>(tmpResult); - if(NULL!=dice) + + Result* tmpResult = previous->getResult(); + while(NULL!=tmpResult) { - ///@todo improve here to set homogeneous while is really - m_diceResult->setHomogeneous(false); - foreach(Die* die, dice->getResultList()) + DiceResult* dice = dynamic_cast<DiceResult*>(tmpResult); + if(NULL!=dice) { - if(!m_diceResult->getResultList().contains(die)) + ///@todo improve here to set homogeneous while is really + m_diceResult->setHomogeneous(false); + foreach(Die* die, dice->getResultList()) { - m_diceResult->getResultList().append(die); + if(!m_diceResult->getResultList().contains(die)) + { + m_diceResult->getResultList().append(die); + } } } + tmpResult = tmpResult->getPrevious(); } - tmpResult = tmpResult->getPrevious(); } - if(NULL!=m_nextNode) { m_nextNode->run(this); |