/// <summary> /// 初始化系统 /// </summary> private void InitSystem() { root = GameObject.Find("UI Root"); //ps初始化 if (ps == null) { ps = transform.GetComponent <PanelSwitch>(); Debug.Log("PanelSwitch 再获取"); } ps.Init(); //im初始化 if (im == null) { im = transform.GetComponent <ImageManager>(); Debug.Log("ImageManager 再获取"); } //dm初始化 dm = DataManager.GetInstance(); //em初始化 em = EventManager.GetInstance(); //eb初始化 EffectBuilder.Init(im, sm, CharacterManager.GetInstance()); //nf初始化 nodeFactory = NodeFactory.GetInstance(); nodeFactory.Init(dm, root, ps); }