Class: ClientInterface

Inherits:
Object
  • Object
show all
Defined in:
lib/software_challenge_client/client_interface.rb

Overview

The interface a client should implement to work with the gem.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#gamestateObject

Is updated by the gem, when a new gamestate is received from the server.



6
7
8
# File 'lib/software_challenge_client/client_interface.rb', line 6

def gamestate
  @gamestate
end

Instance Method Details

#move_requestedMove

Is called when the server requests a move from the client.

Returns:

  • (Move)

    Needs to return a valid move.



10
11
12
# File 'lib/software_challenge_client/client_interface.rb', line 10

def move_requested
  raise 'Not yet implemented'
end