private void enableInput(UnityEngine.InputSystem.Controls.KeyControl key)
 {
     if (key.name == "upArrow")
     {
         jumpAction.Enable();
     }
     else if (key.name == "downArrow")
     {
         slideAction.Enable();
     }
     else if (key.name == "leftArrow")
     {
         moveLeftAction.Enable();
     }
     else if (key.name == "rightArrow")
     {
         moveRightAction.Enable();
     }
 }
    public IEnumerator StartTutorial(UnityEngine.InputSystem.Controls.KeyControl key = null, SwipeAction swipe = SwipeAction.Nil)
    {
        anim.enabled        = false;
        waitForTutorial     = true;
        AudioListener.pause = true;
        if (key != null && swipe != SwipeAction.Nil)
        {
            enableInput(key);
            yield return(new WaitUntil(() => (key.isPressed || latestSwipe == swipe)));
        }
        else
        {
            yield return(new WaitForSeconds(3f));
        }
        waitForTutorial     = false;
        anim.enabled        = true;
        AudioListener.pause = false;

        if (StopTutorial != null)
        {
            StopTutorial.Invoke();
        }
    }