Class: TTT::Player
- Inherits:
-
Shared::Player
- Object
- Shared::Player
- TTT::Player
- Defined in:
- lib/games/tictactoe/player.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
Returns the value of attribute value.
Attributes inherited from Shared::Player
#difficulty_level, #name, #type
Instance Method Summary collapse
Methods inherited from Shared::Player
Constructor Details
This class inherits a constructor from Shared::Player
Instance Attribute Details
#value ⇒ Object
Returns the value of attribute value.
5 6 7 |
# File 'lib/games/tictactoe/player.rb', line 5 def value @value end |
Instance Method Details
#post_initialize(args = {}) ⇒ Object
7 8 9 |
# File 'lib/games/tictactoe/player.rb', line 7 def post_initialize(args = {}) @value = args.fetch(:value, "X") end |