Display game board with Board.show_board()
This commit is contained in:
parent
7b49cac308
commit
3784faeaed
2 changed files with 14 additions and 3 deletions
|
@ -35,14 +35,13 @@ class HumanPlayerEngine(PlayerEngine):
|
|||
user_input = input("Please enter player {} move, `print` to display board and `help` possible moves : ".format(
|
||||
self.get_player_name(board._nextPlayer)
|
||||
))
|
||||
move = self.validate_input(user_input, board, player)
|
||||
print("{}".format(move))
|
||||
move = self.validate_input(user_input, board)
|
||||
return move
|
||||
|
||||
@staticmethod
|
||||
def validate_input(input, board):
|
||||
if input == 'print':
|
||||
print("\n{}".format(board.__str__))
|
||||
print(board.show_board())
|
||||
return None
|
||||
|
||||
if input == 'help':
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue