Method: Codeguessing::Game#cur_score

Defined in:
lib/codeguessing/game.rb

#cur_score(name = 'Anonim') ⇒ Object



49
50
51
52
53
54
55
56
# File 'lib/codeguessing/game.rb', line 49

def cur_score(name = 'Anonim')
  hash = cur_game
  hash[:name] = name
  hash[:attempts] = MAX_SIZE - attempts
  hash[:hint_count] = MAX_HINT - hint_count
  hash[:date] = Time.now.to_i
  hash
end