Class: Adam::Kill::Loot
- Inherits:
-
Object
- Object
- Adam::Kill::Loot
- Defined in:
- lib/adam/kill.rb
Overview
Instances of the Loot class represent a piece of loot of a kill.
Accessors:
-
name
- A string describing the name of the item. -
quantity
- An integer describing the quantity of the item. -
dropped
- A boolean describing whether or not this item was dropped.
Instance Attribute Summary collapse
-
#dropped ⇒ Object
Returns the value of attribute dropped.
-
#location ⇒ Object
Returns the value of attribute location.
-
#name ⇒ Object
Returns the value of attribute name.
-
#quantity ⇒ Object
Returns the value of attribute quantity.
Instance Method Summary collapse
-
#initialize {|_self| ... } ⇒ Loot
constructor
A new instance of Loot.
Constructor Details
#initialize {|_self| ... } ⇒ Loot
Returns a new instance of Loot.
184 185 186 |
# File 'lib/adam/kill.rb', line 184 def initialize yield self if block_given? end |
Instance Attribute Details
#dropped ⇒ Object
Returns the value of attribute dropped.
182 183 184 |
# File 'lib/adam/kill.rb', line 182 def dropped @dropped end |
#location ⇒ Object
Returns the value of attribute location.
182 183 184 |
# File 'lib/adam/kill.rb', line 182 def location @location end |
#name ⇒ Object
Returns the value of attribute name.
182 183 184 |
# File 'lib/adam/kill.rb', line 182 def name @name end |
#quantity ⇒ Object
Returns the value of attribute quantity.
182 183 184 |
# File 'lib/adam/kill.rb', line 182 def quantity @quantity end |