EntryEvent2_InitClient.cs 613 B

1234567891011121314151617181920
  1. namespace ET.Client
  2. {
  3. [Event(SceneType.Process)]
  4. public class EntryEvent2_InitClient : AEvent<ET.EventType.EntryEvent2>
  5. {
  6. protected override async ETTask Run(Scene scene, ET.EventType.EntryEvent2 args)
  7. {
  8. Game.AddSingleton<GameSetting>();
  9. //加载战斗相关资源
  10. Game.AddSingleton<BattleResourceMgr>();
  11. Game.AddSingleton<BattleUnitFactory>();
  12. Game.AddSingleton<SkillMgr>();
  13. Game.AddSingleton<UnitMgr>();
  14. Game.AddSingleton<BattleMgr>();
  15. await ETTask.CompletedTask;
  16. }
  17. }
  18. }