public void Init() { MyInvestigateUI = transform.FindChild("Investigate").GetComponent <InvestigateUI>(); MyInvestigateUI.Init(); MyResultUI = transform.FindChild("Result").GetComponent <ResultUI>(); MyResultUI.Init(); MyAccidentUI = transform.FindChild("Accident").GetComponent <AccidentUI>(); MyAccidentUI.Init(); MyCampUI = transform.FindChild("Camp").GetComponent <CampUI>(); MyCampUI.Init(); }
public void Init() { MyInvestigateUI = transform.FindChild("Investigate").GetComponent<InvestigateUI>(); MyInvestigateUI.Init(); MyResultUI = transform.FindChild("Result").GetComponent<ResultUI>(); MyResultUI.Init(); MyAccidentUI = transform.FindChild("Accident").GetComponent<AccidentUI>(); MyAccidentUI.Init(); MyCampUI = transform.FindChild("Camp").GetComponent<CampUI>(); MyCampUI.Init(); }
//결과창 출력. void ShowResultUI() { ResultUI ui = UIManager.Instance.LoadPopupUI("ResultUI").GetComponent <ResultUI>(); ui.Init(isGameResult, currentScore); if (DataManager.Instance.bestScore < currentScore) { DataManager.Instance.bestScore = currentScore; PlayerPrefs.SetInt("BestScore", currentScore); } }