Class: Gemwarrior::LockerCorner

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

Instance Attribute Summary collapse

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

#initializeLockerCorner

Returns a new instance of LockerCorner.



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

def initialize
  super

  self.name         = 'locker_corner'
  self.name_display = 'Locker (Corner)'
  self.description  = 'The top corner of what appears to be a small locker is slightly sticking up from the sand floor.'
  self.takeable     = false
  self.useable      = true
end

Instance Attribute Details

#lockedObject

Returns the value of attribute locked.



8
9
10
# File 'lib/gemwarrior/entities/items/locker_corner.rb', line 8

def locked
  @locked
end

Instance Method Details

#use(world) ⇒ Object



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

def use(world)
  puts 'Pulling with all your might on the corner of the locker doesn\'t get it it budge one inch. Some other method is going to be needed.'

  { type: nil, data: nil }
end