class RubyTictactoe::UI

Attributes

io[RW]

Public Class Methods

new() click to toggle source
# File lib/ui.rb, line 5
def initialize
  @io = Kernel
end

Public Instance Methods

first_move_message(marker) click to toggle source
# File lib/ui.rb, line 9
def first_move_message(marker)
  "Player '#{marker}' goes first."
end
next_move_message(marker) click to toggle source
# File lib/ui.rb, line 13
def next_move_message(marker)
  "Player '#{marker}': Make your move."
end
tie_game_message() click to toggle source
# File lib/ui.rb, line 21
def tie_game_message
  "GAME OVER! It's a tie!"
end
winning_game_message(marker) click to toggle source
# File lib/ui.rb, line 17
def winning_game_message(marker)
  "GAME OVER! Player '#{marker}' wins!"
end