Class: Cleric

Inherits:
Mobs
  • Object
show all
Defined in:
lib/mobs.rb

Overview

playable character roles each role will have a focus, like healing or magic spells

Instance Attribute Summary collapse

Attributes inherited from Mobs

#agi, #armor, #buff_drink, #buff_food, #coin, #cur_hp, #cur_mana, #dmg, #dodge, #hp, #int, #lvl, #mana, #name, #str, #xp

Instance Method Summary collapse

Constructor Details

#initialize(str = 12, agi = 12, int = 10, dmg = 5, armor = 8, hp = 6, cur_hp = 6, dodge = 5, mana = 12, cur_mana = 12, xp = 0, lvl = 1, coin = 0, name = "Cleric") ⇒ Cleric

Returns a new instance of Cleric.



33
34
35
36
37
38
# File 'lib/mobs.rb', line 33

def initialize(str=12, agi=12, int=10, dmg=5, armor=8, hp=6, cur_hp=6, dodge=5, mana=12, cur_mana=12, xp=0, lvl=1, coin=0, name="Cleric")
  super(str,agi,int,dmg,armor,hp,cur_hp,dodge,mana,cur_mana,xp,lvl,coin,name)
  @buff_food = false
  @buff_drink = false
  @spell_buff = false
end

Instance Attribute Details

#spell_buffObject

clerics can heal themselves, and even put their HP’s above max during combat, as a buffer



31
32
33
# File 'lib/mobs.rb', line 31

def spell_buff
  @spell_buff
end