title: When i use Invoke to a method i want to use i can't call it anymore?
body: <p>I started to learn coding myself by watching videos, reading web articles etc. and i thought that learning by doing would suit better for me so i started to make a game with Unity through Brackeys tutorial videos.</p>
  <pre><code>using UnityEngine.SceneManagement;
  using UnityEngine;
  
  public class gameManager : MonoBehaviour
  {
      bool hasGameEnded = false;
  
      public float restartDelay = 1f;
      public void endGame()
      {
          if (hasGameEnded == false)
          {
              
              hasGameEnded = true;
              Invoke(&quot;Restart&quot;, 2f);
          }
  
          void Restart()
          {
  
              SceneManager.LoadScene(SceneManager.GetActiveScene().name);
  
          }
  
      }
  
  </code></pre>
  <p>So my problem here is when i use invoke with the method Restart none of the callings works.
  &quot;Warning    CS8321  The local function 'Restart' is declared but never used&quot; Thats the error i get.</p>
  <p>If wanted i can show where and how i used the endGame method. Thanks for any kind of help.</p>