YAPOG  0.0.1
Yet Another Pokemon Online Game
yap::PokemonExperience Class Reference

#include <PokemonExperience.hpp>

Inheritance diagram for yap::PokemonExperience:
Collaboration diagram for yap::PokemonExperience:

List of all members.

Public Member Functions

 PokemonExperience ()
void Init (UInt32 experience)
void InitFromLevel (UInt16 level)
UInt32 GetValue () const
 Getters.
UInt32 GetExperienceToNextLevel () const
UInt32 GetTotalExperienceToNextLevel () const
float GetExperiencePercentage ()
int AddExperience (const UInt32 &value)
void ComputeTotalExperienceToNextLevel (UInt16 level)
UInt16 GetLevel ()

Static Public Attributes

static const UInt16 INITIAL_LEVEL_VALUE = 1
static const UInt16 MAX_LEVEL_VALUE = 100

Private Member Functions

 DISALLOW_COPY (PokemonExperience)
virtual UInt32 ComputeExperienceFromLevel (const UInt16 &level)=0

Private Attributes

UInt32 value_
UInt32 totalExperienceToNextLevel_
UInt32 previousValue_
UInt16 currentLevel_

Static Private Attributes

static const UInt32 INITIAL_EXPERIENCE_VALUE = 0
static const UInt32 MAX_EXPERIENCE_VALUE = 2000000

Detailed Description

Definition at line 9 of file PokemonExperience.hpp.


Constructor & Destructor Documentation

yap::PokemonExperience::PokemonExperience ( )

Definition at line 11 of file PokemonExperience.cpp.


Member Function Documentation

int yap::PokemonExperience::AddExperience ( const UInt32 value)

Definition at line 93 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

virtual UInt32 yap::PokemonExperience::ComputeExperienceFromLevel ( const UInt16 level)
privatepure virtual

Implemented in yap::ExperienceErratic, yap::ExperienceFast, yap::ExperienceFluctuating, yap::ExperienceMediumFast, yap::ExperienceMediumSlow, and yap::ExperienceSlow.

Here is the caller graph for this function:

void yap::PokemonExperience::ComputeTotalExperienceToNextLevel ( UInt16  level)

Definition at line 41 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

yap::PokemonExperience::DISALLOW_COPY ( PokemonExperience  )
private
float yap::PokemonExperience::GetExperiencePercentage ( )

Definition at line 63 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UInt32 yap::PokemonExperience::GetExperienceToNextLevel ( ) const

Definition at line 53 of file PokemonExperience.cpp.

Here is the caller graph for this function:

UInt16 yap::PokemonExperience::GetLevel ( )

Definition at line 71 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UInt32 yap::PokemonExperience::GetTotalExperienceToNextLevel ( ) const

Definition at line 58 of file PokemonExperience.cpp.

Here is the caller graph for this function:

UInt32 yap::PokemonExperience::GetValue ( ) const

Getters.

Definition at line 48 of file PokemonExperience.cpp.

Here is the caller graph for this function:

void yap::PokemonExperience::Init ( UInt32  experience)

Definition at line 19 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yap::PokemonExperience::InitFromLevel ( UInt16  level)

Definition at line 26 of file PokemonExperience.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

UInt16 yap::PokemonExperience::currentLevel_
private

Definition at line 38 of file PokemonExperience.hpp.

const uint yap::PokemonExperience::INITIAL_EXPERIENCE_VALUE = 0
staticprivate

Definition at line 39 of file PokemonExperience.hpp.

const UInt16 yap::PokemonExperience::INITIAL_LEVEL_VALUE = 1
static

Definition at line 29 of file PokemonExperience.hpp.

const uint yap::PokemonExperience::MAX_EXPERIENCE_VALUE = 2000000
staticprivate

Definition at line 40 of file PokemonExperience.hpp.

const UInt16 yap::PokemonExperience::MAX_LEVEL_VALUE = 100
static

Definition at line 30 of file PokemonExperience.hpp.

UInt32 yap::PokemonExperience::previousValue_
private

Definition at line 37 of file PokemonExperience.hpp.

UInt32 yap::PokemonExperience::totalExperienceToNextLevel_
private

Definition at line 36 of file PokemonExperience.hpp.

UInt32 yap::PokemonExperience::value_
private

Definition at line 35 of file PokemonExperience.hpp.


The documentation for this class was generated from the following files: