private bool InitializeBundle() { if (!Bundles.Init(InitPath)) { throw new FileNotFoundException("bundle manifest not exist."); } var bundle = Bundles.LoadSync(ABTool.MainAssetBundleBuildName); if (bundle == null) { throw new FileNotFoundException("assets manifest not exist."); } TextAsset xml = bundle.LoadAsset <TextAsset>(ABTool.ManifestPath.GetFileName()); if (xml == null) { throw new FileNotFoundException("assets manifest not exist."); } using (var reader = new StringReader(xml.text)) { Instance.manifestXML.Load(reader.ReadToEnd()); reader.Close(); } bundle.Release(); Resources.UnloadAsset(xml); xml = null; return(true); }