-
Notifications
You must be signed in to change notification settings - Fork 1
/
move.cc
179 lines (171 loc) · 3.88 KB
/
move.cc
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
#include "move.h"
Move::Move()
{
m_type = Type::Element::NORMAL;
m_power = 0;
m_acc = 0;
m_name = "Retard pokemon";
}
Move::Move(Type type, int power, float acc)
{
set(type, power, acc);
m_name = "new";
}
Move::Move(int type, int power, float acc)
{
m_type = type;
m_power = power;
m_acc = acc;
m_name = "New";
}
Move::Move(NameMove name)
{
set(name);
}
void Move::set(Type type, int power, float acc)
{
m_type = type;
m_power = power;
m_acc = acc;
m_name = "New";
}
void Move::set(NameMove name)
{
switch (name)
{
case NameMove::BUBBLE:
m_type = Type::Element::WATER;
m_power = 40;
m_acc = 1;
m_name = "Bubble";
break;
case NameMove::WATER_GUN:
m_type = Type::Element::WATER;
m_power = 75;
m_acc = 1;
m_name = "Water Gun";
break;
case NameMove::WATERFALL:
m_type = Type::Element::WATER;
m_power = 110;
m_acc = 1;
m_name = "Waterfall";
break;
case NameMove::THUNDERSHOCK:
m_type = Type::Element::THUNDER;
m_power = 40;
m_acc = 1;
m_name = "Thundershock";
break;
case NameMove::THUNDERBOLT:
m_type = Type::Element::THUNDER;
m_power = 90;
m_acc = 1;
m_name = "Thunderbolt";
break;
case NameMove::THUNDER:
m_type = Type::Element::THUNDER;
m_power = 110;
m_acc = 0.70;
m_name = "Thunder";
break;
case NameMove::FLAMETHROWER:
m_type = Type::Element::FIRE;
m_power = 90;
m_acc = 1;
m_name = "Flamethrower";
break;
case NameMove::FIRE_BLAST:
m_type = Type::Element::FIRE;
m_power = 110;
m_acc = 0.85;
m_name = "Fire blast";
break;
case NameMove::FIRE_SPIN:
m_type = Type::Element::FIRE;
m_power = 35;
m_acc = 0.85;
m_name = "Fire spin";
break;
case NameMove::AURORA_BEAM:
m_type = Type::Element::ICE;
m_power = 65;
m_acc = 1;
m_name = "Aurora beam";
break;
case NameMove::BLIZZARD:
m_type = Type::Element::ICE;
m_power = 110;
m_acc = 0.70;
m_name = "Blizzard";
break;
case NameMove::ICE_BEAM:
m_type = Type::Element::ICE;
m_power = 90;
m_acc = 1;
m_name = "Ice beam";
break;
case NameMove::THRASH:
m_type = Type::Element::NORMAL;
m_power = 120;
m_acc = 1;
m_name = "Thrash";
break;
case NameMove::SCRATCH:
m_type = Type::Element::NORMAL;
m_power = 40;
m_acc = 1;
m_name = "Scratch";
break;
case NameMove::SKULL_BASH:
m_type = Type::Element::NORMAL;
m_power = 130;
m_acc = 1;
m_name = "Skull bash";
break;
case NameMove::ROCK_SLIDE:
m_type = Type::Element::EARTH;
m_power = 75;
m_acc = 0.9;
m_name = "Rock slide";
break;
case NameMove::SOLARBEAM:
m_type = Type::Element::EARTH;
m_power = 120;
m_acc = 1;
m_name = "Solarbeam";
break;
case NameMove::RAZOR_LEAF:
m_type = Type::Element::EARTH;
m_power = 55;
m_acc = 0.95;
m_name = "Razor leaf";
break;
case NameMove::WING_ATTACK:
m_type = Type::Element::WIND;
m_power = 60;
m_acc = 1;
m_name = "Wing attack";
break;
case NameMove::SKY_ATTACK:
m_type = Type::Element::WIND;
m_power = 140;
m_acc = 0.9;
m_name = "Sky attck";
break;
case NameMove::PECK:
m_type = Type::Element::WIND;
m_power = 35;
m_acc = 1;
m_name = "Peck";
break;
}
}
string Move::name() const
{
return m_name;
}
Type Move::get_Type()
{
return m_type;
}