| 1234567891011121314151617 |
- using System.Collections.Generic;
- using UnityEngine.SceneManagement;
- using YooAsset;
- namespace ET.Client
- {
- /// <summary>
- /// 用来管理资源,生命周期跟随Parent,比如CurrentScene用到的资源应该用CurrentScene的ResourcesLoaderComponent来加载
- /// 这样CurrentScene释放后,它用到的所有资源都释放了
- /// </summary>
- [ComponentOf]
- public class ResourcesLoaderComponent : Entity, IAwake, IAwake<string>, IDestroy
- {
- public ResourcePackage package;
- public Dictionary<string, HandleBase> handlers = new();
- }
- }
|