using UnityEngine; using System.Collections; using UnityEngine.UI; public class BtnScript : MonoBehaviour { public Button OkBtn; public Image img; public Text text; // Use this for initialization void Start () { OkBtn.onClick.AddListener (() => { Invoke("Onclick",5f); text.text = " "; img.color = new Color(255f,255f,255f,255f); }); } // Update is called once per frame void Update () { } void Onclick(){ Application.LoadLevel ("Scene/Main"); } }