void OnStart(EUIPage currentPage) { if (currentPage == EUIPage.CONNECTION) { OnStart(); } }
void SetUI(EUIPage eUIPage) { if (eUIPage != CurrentUIPage) { foreach (KeyValuePair <EUIPage, GameObject> entry in UIPageDict) { entry.Value.SetActive(entry.Key.Equals(eUIPage)); } CurrentUIPage = eUIPage; OnChangePage.Invoke(CurrentUIPage); } }