コード例 #1
0
ファイル: ModManager.cs プロジェクト: Caker-wxj/modioUNITY
        public static void DeleteInactiveBuilds(ModProfile profile)
        {
            string buildDir = CacheClient.GenerateModBuildsDirectoryPath(profile.id);

            string[] buildFilePaths = Directory.GetFiles(buildDir, "*.*");

            foreach (string buildFile in buildFilePaths)
            {
                if (Path.GetFileNameWithoutExtension(buildFile)
                    != profile.activeBuild.id.ToString())
                {
                    CacheClient.DeleteFile(buildFile);
                }
            }
        }
コード例 #2
0
ファイル: CacheClient.cs プロジェクト: Caker-wxj/modioUNITY
 public static string GenerateModBinaryZipFilePath(int modId, int modfileId)
 {
     return(CacheClient.GenerateModBuildsDirectoryPath(modId)
            + modfileId + ".zip");
 }