Class: Wowr::Classes::Stamina

Inherits:
BaseStat
  • Object
show all
Defined in:
lib/wowr/character.rb

Instance Attribute Summary collapse

Attributes inherited from BaseStat

#base, #effective

Instance Method Summary collapse

Constructor Details

#initialize(elem) ⇒ Stamina

Returns a new instance of Stamina.



353
354
355
356
357
358
# File 'lib/wowr/character.rb', line 353

def initialize(elem)
	@base 			= elem[:base].to_i
	@effective 	= elem[:effective].to_i
	@health 		= elem[:health].to_i
	@pet_bonus 	= elem[:petBonus].to_i == -1 ? nil : elem[:petBonus].to_i
end

Instance Attribute Details

#healthObject (readonly)

Returns the value of attribute health.



352
353
354
# File 'lib/wowr/character.rb', line 352

def health
  @health
end

#pet_bonusObject (readonly)

Returns the value of attribute pet_bonus.



352
353
354
# File 'lib/wowr/character.rb', line 352

def pet_bonus
  @pet_bonus
end