private void Awake() { DontDestroyOnLoad(gameObject); Current = this; if (Main.m_Resource.Mode == ResourceLoadMode.Resource) { Log.Error("热更新初始化失败:热更新库不支持使用Resource加载模式!"); return; } }
protected override void OnEnable() { _target = target as ILHotfixManager; _ILHotfixIsCreated = false; string hotfixDirectory = Application.dataPath + _ILHotfixDirectory; string hotfixEnvironmentPath = Application.dataPath + _ILHotfixEnvironmentPath; string hotfixAssemblyDefinitionPath = Application.dataPath + _ILHotfixAssemblyDefinitionPath; if (Directory.Exists(hotfixDirectory)) { if (File.Exists(hotfixEnvironmentPath)) { if (File.Exists(hotfixAssemblyDefinitionPath)) { _ILHotfixIsCreated = true; } } } }