Module: Lich::Gemstone::Experience

Defined in:
documented/gemstone/experience.rb

Overview

Provides methods to access experience-related data This module includes methods to retrieve various experience metrics.

Examples:

Accessing current field experience

current_fxp = Lich::Gemstone::Experience.fxp_current

Class Method Summary collapse

Class Method Details

.axpInteger

Retrieves the ascension experience

Examples:

current_axp = Lich::Gemstone::Experience.axp

Returns:

  • (Integer)

    the current ascension experience



50
51
52
# File 'documented/gemstone/experience.rb', line 50

def self.axp
  Infomon.get("experience.ascension_experience")
end

.deaths_stingInteger

Retrieves the deaths sting value

Examples:

deaths_sting_value = Lich::Gemstone::Experience.deaths_sting

Returns:

  • (Integer)

    the current deaths sting value



106
107
108
# File 'documented/gemstone/experience.rb', line 106

def self.deaths_sting
  Infomon.get("experience.deaths_sting")
end

.deedsInteger

Retrieves the deeds value

Examples:

deeds_value = Lich::Gemstone::Experience.deeds

Returns:

  • (Integer)

    the current deeds value



98
99
100
# File 'documented/gemstone/experience.rb', line 98

def self.deeds
  Infomon.get("experience.deeds")
end

.expInteger

Retrieves the current experience

Examples:

current_exp = Lich::Gemstone::Experience.exp

Returns:

  • (Integer)

    the current experience



42
43
44
# File 'documented/gemstone/experience.rb', line 42

def self.exp
  Stats.exp
end

.fameInteger

Retrieves the fame value

Examples:

fame_value = Lich::Gemstone::Experience.fame

Returns:

  • (Integer)

    the current fame value



18
19
20
# File 'documented/gemstone/experience.rb', line 18

def self.fame
  Infomon.get("experience.fame")
end

.fxp_currentInteger

Retrieves the current field experience

Examples:

current_fxp = Lich::Gemstone::Experience.fxp_current

Returns:

  • (Integer)

    the current field experience



26
27
28
# File 'documented/gemstone/experience.rb', line 26

def self.fxp_current
  Infomon.get("experience.field_experience_current")
end

.fxp_maxInteger

Retrieves the maximum field experience

Examples:

max_fxp = Lich::Gemstone::Experience.fxp_max

Returns:

  • (Integer)

    the maximum field experience



34
35
36
# File 'documented/gemstone/experience.rb', line 34

def self.fxp_max
  Infomon.get("experience.field_experience_max")
end

.lteInteger

Retrieves the long-term experience

Examples:

long_term_exp = Lich::Gemstone::Experience.lte

Returns:

  • (Integer)

    the long-term experience



90
91
92
# File 'documented/gemstone/experience.rb', line 90

def self.lte
  Infomon.get("experience.long_term_experience")
end

.percent_axpFloat

Calculates the percentage of ascension experience

Examples:

percent = Lich::Gemstone::Experience.percent_axp

Returns:

  • (Float)

    the percentage of ascension experience



74
75
76
# File 'documented/gemstone/experience.rb', line 74

def self.percent_axp
  (axp.to_f / txp.to_f) * 100
end

.percent_expFloat

Calculates the percentage of current experience

Examples:

percent = Lich::Gemstone::Experience.percent_exp

Returns:

  • (Float)

    the percentage of current experience



82
83
84
# File 'documented/gemstone/experience.rb', line 82

def self.percent_exp
  (exp.to_f / txp.to_f) * 100
end

.percent_fxpFloat

Calculates the percentage of current field experience

Examples:

percent = Lich::Gemstone::Experience.percent_fxp

Returns:

  • (Float)

    the percentage of current field experience



66
67
68
# File 'documented/gemstone/experience.rb', line 66

def self.percent_fxp
  (fxp_current.to_f / fxp_max.to_f) * 100
end

.txpInteger

Retrieves the total experience

Examples:

total_xp = Lich::Gemstone::Experience.txp

Returns:

  • (Integer)

    the total experience



58
59
60
# File 'documented/gemstone/experience.rb', line 58

def self.txp
  Infomon.get("experience.total_experience")
end