using UnityEngine; public class InitSettingTask : LaunchTask { public override float expectTime { get { return LocalSave.GetFloat("InitSettingTask_ExpectTime", 1f); } protected set { LocalSave.SetFloat("InitSettingTask_ExpectTime", value); } } public override void Begin() { ShaderUtility.InitGlobalParams(); SoundPlayer.CreateSoundPlayer(); //SoundPlayer.Instance.PlayLoginMusic(); SystemSetting.Instance.SetSoundVolume(SystemSetting.Instance.GetSoundVolume()); SystemSetting.Instance.SetSoundEffect(SystemSetting.Instance.GetSoundEffect()); SystemSetting.Instance.SetGameFps(SystemSetting.Instance.GetGameFps()); SystemSetting.Instance.LetFPSUnLimit(); DebugUtility.Instance.Init(); DebugUtility.Instance.CreateDebugRoot(); GameObjectPoolManager.Instance.gameObject.name = "GameObjectPool"; GameObjectPoolManager.Instance.Initialize(); //ExceptionCatcher.Init(); //ExceptionCatcher.Catch(); GlobalTimeEvent.Instance.Begin(); PackageRegedit.Init(); Clock.Init(); done = true; } public override void End() { expectTime = timer; } public override void Update() { timer += Time.deltaTime; } }