Esempio n. 1
0
                          str(predicted_action[1]) + ') -> (' +
                          str(predicted_action[2]) + ',' +
                          str(predicted_action[3]) + ')')

        # Player 2
        else:
            print_board(game.state)
            selected_move = human.get_move(game, chain=False)
            game.play_action(selected_move)
            print('Human moved:', end="\t")
            print('(' + str(selected_move[0]) + ',' + str(selected_move[1]) +
                  ') -> (' + str(selected_move[2]) + ',' +
                  str(selected_move[3]) + ')')
            if clone.if_attack_move(selected_move):
                while game.attack_move_available(
                        game.remove_non_attacks(
                            game.remove_except_current(selected_move))):
                    selected_move = human.get_move(game,
                                                   chain=True,
                                                   prev_move=selected_move)
                    game.play_action(selected_move)
                    print('Human moved:', end="\t")
                    print('(' + str(selected_move[0]) + ',' +
                          str(selected_move[1]) + ') -> (' +
                          str(selected_move[2]) + ',' + str(selected_move[3]) +
                          ')')
        game.flip_perspective()
        step += 1
        if step > 120:
            break
            draw = True
    if draw: