Exemplo n.º 1
0
 public void FourByFour()
 {
     StartBotGame();
     Settings.BoardDimensions = new Vector2Int(4, 4);
     SolverParser.Main(_4x4StrategyFile);
     _gameManager.ResetGameWithNewAgents(new Agent[] { _jingYangPlayer, _jingYangOpponent });
 }
Exemplo n.º 2
0
 public void ThreeByThree()
 {
     StartBotGame();
     Settings.BoardDimensions = new Vector2Int(3, 3);
     SolverParser.Main(_3x3StrategyFile);
     _gameManager.ResetGameWithNewAgents(new Agent[] { _jingYangPlayer, _jingYangOpponent });
 }
Exemplo n.º 3
0
    public void Initialize()
    {
        SolverParser.Main(Application.streamingAssetsPath + "/" + _defaultStrategyFile);
        var name         = SolverParser.IssueCommand(BenzeneCommands.name);
        var expectedName = (_isUsingStandaloneExecutable) ? "= jingyang" : "= JY";

        if (expectedName != name)
        {
            Debug.LogError("Failed to start jingyang player. Instead got: " + name);
            return;
        }
        if (!_isUsingStandaloneExecutable)
        {
            //Standalone executables automatically determine boardsize but benzene defaults to 13x13
            SolverParser.IssueCommand(BenzeneCommands.boardsize(new Vector2Int(9, 9)));
        }
        if (_callback != null)
        {
            _callback(new Move(new Vector2Int((Settings.BoardDimensions.x) / 2, (Settings.BoardDimensions.y - 1) / 2)));
        }
    }