lib/game.rb in codebreaker_paratskiy-0.2.1 vs lib/game.rb in codebreaker_paratskiy-0.2.2

- old
+ new

@@ -2,10 +2,10 @@ require_relative 'services/statistic_service' class Game attr_accessor :player_name, :secret_code, :user_code, :attempts, :hints, :difficulty_name attr_reader :stats, :secret_code_for_hint - def initialize(player_name = DEFAULT_NAME, difficulty = DIFFICULTIES[:default]) + def initialize(player_name, difficulty) @stats = Statistic.stats @player_name = player_name @difficulty_name = DIFFICULTIES.key(difficulty).to_s @attempts = difficulty[:attempts] @hints = difficulty[:hints]