Exemplo n.º 1
0
    public static void RunBuild(GameLoopMode mode)
    {
        var buildPath = GetBuildPath();
        var buildExe  = GetBuildExe(mode);

        Debug.Log("Starting " + buildPath + "/" + buildExe);
        var process = new System.Diagnostics.Process();

        process.StartInfo.FileName         = Application.dataPath + "/../" + buildPath + "/" + buildExe;
        process.StartInfo.WorkingDirectory = buildPath;
        process.Start();
    }
Exemplo n.º 2
0
    static DateTime TimeLastBuildGame(GameLoopMode mode)
    {
        string buildPath = GetBuildPath();

        if (mode == GameLoopMode.Server)
        {
            buildPath += "/Server";
        }
        else if (mode == GameLoopMode.Client)
        {
            buildPath += "/Client";
        }
        else if (mode == GameLoopMode.AI)
        {
            buildPath += "/AI";
        }

        return(Directory.GetLastWriteTime(buildPath));
    }
Exemplo n.º 3
0
 static string GetBuildExe(GameLoopMode mode)
 {
     if (mode == GameLoopMode.Server)
     {
         return("Server/Server.exe");
     }
     else if (mode == GameLoopMode.Client)
     {
         return("Client/Client.exe");
     }
     else if (mode == GameLoopMode.AI)
     {
         return("AI/AI.exe");
     }
     else
     {
         return("");
     }
 }