Пример #1
0
    void detectSingleTap()
    {
        if (Input.GetKeyDown((KeyCode.Escape)) && !doubleTapped)
        {
            switch (Application.loadedLevel)
            {
            case 1:
                toastManager.showToastOnUiThread("Press again to quit");
                break;

            case 2:
                Application.LoadLevel(1);    //Load main menu
                break;

            case 9:
                Application.LoadLevel(1);    //Load main menu
                break;

            default:
                toastManager.showToastOnUiThread("Press again to return to main menu");
                break;
            }
        }
    }