YAPOG  0.0.1
Yet Another Pokemon Online Game
NatureInfo.cpp
Go to the documentation of this file.
2 
3 namespace yap
4 {
5  const float NatureInfo::INITIAL_FACTOR_VALUE = 1.f;
6 
8  : staticID_ (0)
9  , name_ ()
10  , attackFactor_ (INITIAL_FACTOR_VALUE)
11  , defenseFactor_ (INITIAL_FACTOR_VALUE)
12  , specialAttackFactor_ (INITIAL_FACTOR_VALUE)
13  , specialDefenseFactor_ (INITIAL_FACTOR_VALUE)
14  , speedFactor_ (INITIAL_FACTOR_VALUE)
15  {
16  }
17 
19  : staticID_ (id)
20  , name_ ()
21  , attackFactor_ (INITIAL_FACTOR_VALUE)
22  , defenseFactor_ (INITIAL_FACTOR_VALUE)
23  , specialAttackFactor_ (INITIAL_FACTOR_VALUE)
24  , specialDefenseFactor_ (INITIAL_FACTOR_VALUE)
25  , speedFactor_ (INITIAL_FACTOR_VALUE)
26  {
27  }
28 
30  : staticID_ (copy.staticID_)
31  , name_ (copy.name_)
32  , attackFactor_ (copy.attackFactor_)
33  , defenseFactor_ (copy.defenseFactor_)
34  , specialAttackFactor_ (copy.specialAttackFactor_)
35  , specialDefenseFactor_ (copy.specialDefenseFactor_)
36  , speedFactor_ (copy.speedFactor_)
37  {
38  }
39 
41  {
42  return new NatureInfo (*this);
43  }
44 
45  const ID& NatureInfo::GetID () const
46  {
47  return staticID_;
48  }
49 
50  const String& NatureInfo::GetName () const
51  {
52  return name_;
53  }
54 
55  const float& NatureInfo::GetAttackFactor () const
56  {
57  return attackFactor_;
58  }
59 
60  const float& NatureInfo::GetDefenseFactor () const
61  {
62  return defenseFactor_;
63  }
64 
65  const float& NatureInfo::GetSpecialAttackFactor () const
66  {
67  return specialAttackFactor_;
68  }
69 
71  {
72  return specialDefenseFactor_;
73  }
74 
75  const float& NatureInfo::GetSpeedFactor () const
76  {
77  return speedFactor_;
78  }
79 
81  void NatureInfo::SetID (const ID& id)
82  {
83  staticID_ = id;
84  }
85 
86  void NatureInfo::SetName (const String& name)
87  {
88  name_ = name;
89  }
90 
91  void NatureInfo::SetAttackFactor (const float& factor)
92  {
93  attackFactor_ = factor;
94  }
95 
96  void NatureInfo::SetDefenseFactor (const float& factor)
97  {
98  defenseFactor_ = factor;
99  }
100 
101  void NatureInfo::SetSpecialAttackFactor (const float& factor)
102  {
103  specialAttackFactor_ = factor;
104  }
105 
106  void NatureInfo::SetSpecialDefenseFactor (const float& factor)
107  {
108  specialDefenseFactor_ = factor;
109  }
110 
111  void NatureInfo::SetSpeedFactor (const float& factor)
112  {
113  speedFactor_ = factor;
114  }
115 
116 } // namespace yap