public GuiUiSceneBase ActiveAloneUiScene(string prefabsName, params object[] args) { if (AloneScene != null) { UnityEngine.Object.DestroyObject(AloneScene.gameObject); AloneScene = null; } if (prefabsName != "") { AloneScene = LoadResource_UIPrefabs(prefabsName).GetComponent <GuiUiSceneBase>(); if (AloneScene != null) { AloneScene.SetTransferParameter(args); } } return(AloneScene); }
public GuiUiSceneBase ActivePoolingScene(string prefabsName, params object[] args) { if (prefabsName == "") { return(null); } GuiUiSceneBase s = LoadResource_UIPrefabs(prefabsName).GetComponent <GuiUiSceneBase>(); if (s == null) { return(null); } if (PoolingSceneList.ContainsKey(s.uiSceneId)) { UnityEngine.Object.DestroyObject(s.gameObject); return(null); } PoolingSceneList.Add(s.uiSceneId, s); s.SetTransferParameter(args); return(s); }