Class: Gemwarrior::Bullet

Inherits:
Item show all
Defined in:
lib/gemwarrior/entities/items/bullet.rb

Constant Summary collapse

USE_TEXT =

CONSTANTS

'** ZZZZZ **'

Instance Attribute Summary

Attributes inherited from Item

#is_armor, #is_weapon

Attributes inherited from Entity

#consumable, #describe, #describe_detailed, #description, #display_shopping_cart, #equippable, #equipped, #name, #name_display, #number_of_uses, #takeable, #talkable, #useable, #useable_battle, #used, #used_again

Instance Method Summary collapse

Methods inherited from Item

#describe_detailed

Methods inherited from Entity

#puts

Constructor Details

#initializeBullet

Returns a new instance of Bullet.



11
12
13
14
15
16
17
18
# File 'lib/gemwarrior/entities/items/bullet.rb', line 11

def initialize
  super

  self.name         = 'bullet'
  self.name_display = 'Bullet'
  self.description  = 'Gunpowder packed into a small metallic tube, ready to be fired from...something.'
  self.takeable     = true
end

Instance Method Details

#use(world) ⇒ Object



20
21
22
23
# File 'lib/gemwarrior/entities/items/bullet.rb', line 20

def use(world)
  puts 'You could throw this at a monster, but somehow the force of it would be less than desired.'
  { type: nil, data: nil }
end