Sha256: 447ecaf95074e7f9fe116430b6b4828edb62644a67c53a267cd69f3a7265cf1d

Contents?: true

Size: 402 Bytes

Versions: 4

Compression:

Stored size: 402 Bytes

Contents

module Hands
  class Player
    # @return [String] Their name
    attr_accessor :name

    # @return [Hand] Their hand
    attr_accessor :hand

    # @return [Table] The {Table} they are sitting at
    attr_accessor :table

    # Initialize a new {Player}
    # @param [String] name {Player}'s name
    def initialize(name = nil)
      @hand = Hand.new
      self.name = name if name
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
hands-0.3.0 lib/hands/player.rb
hands-0.2.1 lib/hands/player.rb
hands-0.2.0 lib/hands/player.rb
hands-0.1.0 lib/hands/player.rb