예제 #1
0
 // 유틸 : PackingAssetBundles 패킹
 static void PackingAssetBundles(BuildTarget eTarget, eBundlePackType eType, bool bIsDelOriginal)
 {
     Debug.LogFormat("** AssetBundles Packing Start({0}) -> {1}", eTarget, DateTime.Now.ToString("yyyy-MM-dd [ HH:mm:ss ]"));
     {
         SHAssetBundleMaker.PackingAssetBundle(eTarget, eType, bIsDelOriginal);
         AssetDatabase.Refresh();
     }
     Debug.LogFormat("** AssetBundles Packing End({0}) -> {1}", eTarget, DateTime.Now.ToString("yyyy-MM-dd [ HH:mm:ss ]"));
 }
    // 유틸 : 번들패킹 명령
    void StartPacking(int iPlatformType, eBundlePackType ePackType, bool bIsDeleteOriginal, string strOutputPath)
    {
        if (eBundlePackType.None == ePackType)
        {
            return;
        }

        switch ((PlatformType)iPlatformType)
        {
        case PlatformType.AOS:  SHAssetBundleMaker.PackingAssetBundle(BuildTarget.Android, ePackType, bIsDeleteOriginal, strOutputPath); break;

        case PlatformType.IOS:  SHAssetBundleMaker.PackingAssetBundle(BuildTarget.iOS, ePackType, bIsDeleteOriginal, strOutputPath); break;

        case PlatformType.PC:   SHAssetBundleMaker.PackingAssetBundle(BuildTarget.StandaloneWindows, ePackType, bIsDeleteOriginal, strOutputPath); break;

        case PlatformType.ALL:
            SHAssetBundleMaker.PackingAssetBundle(BuildTarget.StandaloneWindows, ePackType, bIsDeleteOriginal, strOutputPath);
            SHAssetBundleMaker.PackingAssetBundle(BuildTarget.iOS, ePackType, bIsDeleteOriginal, strOutputPath);
            SHAssetBundleMaker.PackingAssetBundle(BuildTarget.Android, ePackType, bIsDeleteOriginal, strOutputPath);
            break;
        }
    }