Sha256: 8f40095b74b87d5a48c72540e6f797eefcd90b8edad41c1d960a49075a1f2fe2

Contents?: true

Size: 319 Bytes

Versions: 3

Compression:

Stored size: 319 Bytes

Contents

module TTT
  class Player
    attr_accessor :value, :name, :type, :difficulty_level

    def initialize(args = {})
      @value = args.fetch(:value, "X")
      @name = args.fetch(:name, "Player 1")
      @type = args.fetch(:type, :computer)
      @difficulty_level = args.fetch(:difficulty_level, nil)
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
tic_tac_toe_bfox-0.3.0 lib/tictactoe/player.rb
tic_tac_toe_bfox-0.2.0 lib/tictactoe/player.rb
tic_tac_toe_bfox-0.1.0 lib/tictactoe/player.rb