Sha256: 9958d9ca88f5da3c84f7960167d10c04f31474f0693495aa51e3c90eefc8fb2b

Contents?: true

Size: 688 Bytes

Versions: 7

Compression:

Stored size: 688 Bytes

Contents

# lib/gemwarrior/entities/items/gun.rb
# Item::Gun

require_relative '../item'

module Gemwarrior
  class Gun < Item
    def initialize
      self.name         = 'gun'
      self.description  = 'Pew pew goes this firearm, you suspect.'
      self.atk_lo       = 3
      self.atk_hi       = 5
      self.takeable     = true
      self.useable      = true
      self.equippable   = true
      self.equipped     = false
    end
    
    def use(player = nil)
      puts 'You pull the trigger on the gun, but realize there are no bullets in it. So, it does not do much except cause a barely audible *click* sound.'
      {:type => nil, :data => nil}
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
gemwarrior-0.8.6 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.8.5 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.8.3 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.8.2 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.8.1 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.8.0 lib/gemwarrior/entities/items/gun.rb
gemwarrior-0.7.9 lib/gemwarrior/entities/items/gun.rb