-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathWonderModel.hpp
77 lines (69 loc) · 2.14 KB
/
WonderModel.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
#ifndef WONDERMODEL_HPP
#define WONDERMODEL_HPP
#include <QObject>
#include <QList>
#include <QString>
#include "AdvanceModel.hpp"
class WonderModel : public QObject
{
public:
enum Wonder
{
AMPHITHEATER = 0,
CITY_OF_ATLANTIS,
COLISEUM_OF_DUELS,
GIANT_GILDED_STATUE,
GREAT_WALL_OF_SOLITUDE,
HALL_OF_JUSTICE,
HANGING_GARDENS,
HUGE_MONOLITH,
MOUNTAIN_CITADEL,
PALACE_OF_THE_SENATE
};
private:
Wonder wonder;
int victoryPoints;
int tribesCost;
int goldCost;
bool requiresWood;
bool requiresStone;
bool requiresFood;
bool requiresCity;
QList<AdvanceModel::Advance> advancePrequisites;
QList<QString> otherRequirements;
QList<QString> positiveEffects;
QList<QString> negativeEffects;
public:
WonderModel(Wonder wonder,
int victoryPoints,
int tribesCost,
int goldCost,
bool requiresWood,
bool requiresStone,
bool requiresFood,
bool requiresCity,
const QList<AdvanceModel::Advance> &advancePrequisites,
const QList<QString> &otherRequirements,
const QList<QString> &positiveEffects,
const QList<QString> &negativeEffects,
QObject *parent = 0);
bool advancePrequisitesMet(const QSet<AdvanceModel::Advance> &advancesAquired) const;
static QString listUpWonders(const QMap<WonderModel::Wonder, int> &wonders);
static QString getName(WonderModel::Wonder wonder);
// Get-Methods
Wonder getWonder() const;
QString getName() const;
int getVictoryPoints() const;
int getTribesCost() const;
int getGoldCost() const;
bool getRequiresWood() const;
bool getRequiresStone() const;
bool getRequiresFood() const;
bool getRequiresCity() const;
QList<AdvanceModel::Advance> getAdvancePrequisites() const;
QList<QString> getOtherRequirements() const;
QList<QString> getPositiveEffects() const;
QList<QString> getNegativeEffects() const;
QString getEffects() const;
};
#endif // WONDERMODEL_HPP