-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
78 lines (50 loc) · 1.56 KB
/
main.cpp
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
78
#include <iostream>
#include <string>
#include <array>
#include "Influence.h"
#include "Character.h"
#include "Skill.h"
using namespace std;
array<Skill,7> SkillsArray = {
Skill("Staring"),
Skill("Juggling"),
Skill("Seance"),
Skill("Chemistry"),
Skill("Puns"),
Skill("Burping"),
Skill("Tweets")};
void Initialise();
void ShowCharacter(Character* CharacterPtr);
int main()
{
Initialise();
auto Bob = Character("Bob");
auto Greg = Character();
cout << SkillsArray.size() << endl;
Greg.SetSpeciality(&SkillsArray[(rand() % SkillsArray.size())]);
Influence TestInf;
TestInf.SetInfluenceName("Power");
cout << "Test" << endl;
cout << TestInf.GetInfluenceName() << endl;
cout << Bob.GetCharacterName() << endl;
cout << Greg.GetCharacterName() << endl;
for (auto sk : SkillsArray)
{
cout << sk.GetSkillName() << endl;
}
cout << "---------------" << endl;
ShowCharacter(&Bob);
ShowCharacter(&Greg);
return 0;
}
void Initialise()
{
// TODO Set random seed
}
void ShowCharacter(Character* CharacterPtr)
{
if (!CharacterPtr) { return; }
auto charName = CharacterPtr->GetCharacterName();
auto specName = CharacterPtr->GetSpeciality();
cout << charName << ":->" << specName << endl;
}