Class: Wowr::Classes::Resistance

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(elem) ⇒ Resistance

Returns a new instance of Resistance.



649
650
651
652
# File 'lib/wowr/character.rb', line 649

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

Instance Attribute Details

#pet_bonusObject (readonly)

Returns the value of attribute pet_bonus.



647
648
649
# File 'lib/wowr/character.rb', line 647

def pet_bonus
  @pet_bonus
end

#valueObject (readonly)

Returns the value of attribute value.



647
648
649
# File 'lib/wowr/character.rb', line 647

def value
  @value
end