module StudioGame::GameTurn

Public Class Methods

take_turn(player) click to toggle source
# File lib/studio_game/game_turn.rb, line 8
def self.take_turn(player)
  die = StudioGame::Die.new
  # number_rolled = die.roll (could have made "number_rolled" the case value, but that prints an extra dice value when we audit it.)
  case die.roll
  when 1..2
    player.blam
  when 3..4
    puts "#{player.name} got skipped."
  else
    player.w00t
  end
  
  rand_treasure = StudioGame::TreasureTrove.random
  player.found_treasure(rand_treasure)
  
  
  
end