class ClumsyPlayer

Attributes

boost_factor[R]

Public Class Methods

new(name, health, boost_factor = 2) click to toggle source
Calls superclass method StudioGame::Player::new
# File lib/studio_game/clumsy_player.rb, line 8
def initialize(name, health, boost_factor = 2)
  super(name, health)
  @boost_factor = boost_factor
end

Public Instance Methods

found_treasure(treasure) click to toggle source
Calls superclass method StudioGame::Player#found_treasure
# File lib/studio_game/clumsy_player.rb, line 17
def found_treasure(treasure)
  super Treasure.new(treasure.name, treasure.points / 2.0)
end
w00t() click to toggle source
Calls superclass method StudioGame::Playable#w00t
# File lib/studio_game/clumsy_player.rb, line 13
def w00t
  @boost_factor.times { super }
end