/// <summary> /// 取得Bundle全名(包含后缀). /// </summary> /// <returns>Bundle全名.</returns> /// <param name="iBundleId">Bundle ID.</param> public string GetBundleFullName(string iBundleId) { var strRet = iBundleId; var fileSuffix = BundlesResult.GetInstance().FileSuffix; if (string.IsNullOrEmpty(fileSuffix) == false) { strRet = $"{strRet}.{fileSuffix}"; } return(strRet); }
/// <summary> /// 更新&生成上传列表信息. /// </summary> /// <param name="iBundleType">Bundle Type.</param> /// <param name="iHashCodes">HashCode列表(Unity3d打包生成).</param> public void PushBundleResult(BundleType iBundleType, Dictionary <string, string> iHashCodes = null) { var list = BundlesResult.GetInstance(); if (list == null) { return; } list.AppVersion = BundlesResult.GetInstance().AppVersion; // MainManifest if (BundleType.Normal == iBundleType) { list.AddMainManifestAssetsTarget(); } // 遍历Bundles foreach (var loop in Maps) { if (loop.type != iBundleType) { continue; } string hashCode = null; if (iHashCodes != null) { hashCode = GetHashCodeOfBundle(iHashCodes, loop.id); } // Bundle list.AddTarget(loop, BundleFileType.Bundle, hashCode); if (list.ManifestUpload && BundleType.Scene != loop.type) { // Manifest(Normal) list.AddTarget(loop, BundleFileType.NormalManifest); } } }