Class: Wowr::Classes::Strength

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) ⇒ Strength

Returns a new instance of Strength.



332
333
334
335
336
337
# File 'lib/wowr/character.rb', line 332

def initialize(elem)
	@base				= elem['base'].to_i
	@effective 	= elem['effective'].to_i
	@attack 		= elem['attack'].to_i
	@block 			= elem['block'].to_i == -1 ? nil : elem['block'].to_i
end

Instance Attribute Details

#attackObject (readonly)

Returns the value of attribute attack.



331
332
333
# File 'lib/wowr/character.rb', line 331

def attack
  @attack
end

#blockObject (readonly)

Returns the value of attribute block.



331
332
333
# File 'lib/wowr/character.rb', line 331

def block
  @block
end