// Start is called before the first frame update void Start() { Player.GetSingleton().Init(); this.InitUI(); TUIManager.GetSingleton().OpenUI("UIMain"); AudioManager.GetSingleton().Init(); }
public override void OnInitialize(params object[] parms) { this.TextContent.text = (string)parms[0]; IEnumerator TimeHide() { yield return(new WaitForSeconds(0.5f)); float y = 0; for (int i = 0; i < 30; i++) { y += 0.1f * Time.deltaTime; this.TextNode.transform.position += new Vector3(0, y, 0); yield return(0); } TUIManager.GetSingleton().CloseUI(this); } StartCoroutine(TimeHide()); }
public void Close() { TUIManager.GetSingleton().CloseUI(this); }
public static void ShowTips(string aText) { TUIManager.GetSingleton().OpenUI("UIPopTips", aText); }
private void InitUI() { TUIManager.GetSingleton().Initialize(); TUIManager.GetSingleton().RegisterUI("UI/", "UIMain"); TUIManager.GetSingleton().RegisterUI("UI/", "UIPopTips"); }
// Update is called once per frame void Update() { TUIManager.GetSingleton().UpdateUI(); }