aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/diceresult.cpp
blob: dfdd765dbbdf9a9d468ac34f4db0563c5a666c65 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include "diceresult.h"

DiceResult::DiceResult()
{

}
void DiceResult::insertResult(qint64 die)
{
    m_diceValues.append(die);
}
QList<qint64>& DiceResult::getResultList()
{
    return m_diceValues;
}
qint64  DiceResult::getSum()
{
    qint64 sum=0;
    foreach (qint64 tmp, m_diceValues)
    {
        sum+=tmp;
    }
    return sum;
}