YAPOG  0.0.1
Yet Another Pokemon Online Game
PokemonExperience.hpp
Go to the documentation of this file.
1 #ifndef YAPOG_POKEMONEXPERIENCE_HPP
2 # define YAPOG_POKEMONEXPERIENCE_HPP
3 
4 # include "YAPOG/Macros.hpp"
6 
7 namespace yap
8 {
10  {
12 
13  public:
15 
16  void Init (UInt32 experience);
17  void InitFromLevel (UInt16 level);
18 
19  UInt32 GetValue () const;
20  UInt32 GetExperienceToNextLevel () const;
21  UInt32 GetTotalExperienceToNextLevel () const;
22  float GetExperiencePercentage ();
23 
24  int AddExperience (const UInt32& value);
25 
26  void ComputeTotalExperienceToNextLevel (UInt16 level);
27  UInt16 GetLevel ();
28 
30  static const UInt16 MAX_LEVEL_VALUE;
31 
32  private:
33  virtual UInt32 ComputeExperienceFromLevel (const UInt16& level) = 0;
34 
41  };
42 } // namespace yap
43 
44 #endif // YAPOG_POKEMONEXPERIENCE_HPP