Class: Wowr::Classes::DisenchantItem
- Inherits:
-
Object
- Object
- Wowr::Classes::DisenchantItem
- Defined in:
- lib/wowr/classes.rb
Overview
<item name=“Void Crystal” minCount=“1” maxCount=“2” icon=“inv_enchant_voidcrystal” type=“Enchanting” level=“70” dropRate=“6” id=“22450” quality=“4”></item>
Instance Attribute Summary collapse
-
#drop_rate ⇒ Object
readonly
Returns the value of attribute drop_rate.
-
#icon ⇒ Object
readonly
Returns the value of attribute icon.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#level ⇒ Object
readonly
Returns the value of attribute level.
-
#max_count ⇒ Object
readonly
Returns the value of attribute max_count.
-
#min_count ⇒ Object
readonly
Returns the value of attribute min_count.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#quality ⇒ Object
readonly
Returns the value of attribute quality.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(elem) ⇒ DisenchantItem
constructor
A new instance of DisenchantItem.
Constructor Details
#initialize(elem) ⇒ DisenchantItem
Returns a new instance of DisenchantItem.
1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 |
# File 'lib/wowr/classes.rb', line 1144 def initialize(elem) @name = elem[:name] @id = elem[:id].to_i @icon = elem[:icon] @level = elem[:level].to_i @type = elem[:type] @drop_rate = elem[:dropRate].to_i @min_count = elem[:minCount].to_i @max_count = elem[:maxCount].to_i @quality = elem[:quality].to_i end |
Instance Attribute Details
#drop_rate ⇒ Object (readonly)
Returns the value of attribute drop_rate.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def drop_rate @drop_rate end |
#icon ⇒ Object (readonly)
Returns the value of attribute icon.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def icon @icon end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def id @id end |
#level ⇒ Object (readonly)
Returns the value of attribute level.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def level @level end |
#max_count ⇒ Object (readonly)
Returns the value of attribute max_count.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def max_count @max_count end |
#min_count ⇒ Object (readonly)
Returns the value of attribute min_count.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def min_count @min_count end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def name @name end |
#quality ⇒ Object (readonly)
Returns the value of attribute quality.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def quality @quality end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
1142 1143 1144 |
# File 'lib/wowr/classes.rb', line 1142 def type @type end |