public FinalZone GetInstance()
 {
     if (instance == null)
     {
         instance = this;
     }
     return(instance);
 }
    private void Awake()
    {
        instance    = this;
        reachNumber = 0;

        winPanel.SetActive(false);
        lossPanel.SetActive(false);
        loss = false;

        nextButton.onClick.AddListener(LoadNextPage);
        retryButton.onClick.AddListener(ReloadPage);
        quitButton.onClick.AddListener(GoToMainMenu);
    }
 // Start is called before the first frame update
 void Start()
 {
     if (spawnManager != null)
     {
         spawnManager.Initialize(waypointManager);
         spawnManager.StartSpawners();
     }
     else
     {
         Debug.Log("SpawnManager is NULL!");
     }
     finalzone = FindObjectOfType <FinalZone>();
     finalzone.OnEnemyPassed += () => { PlayerLife--; Enenmypassed++; OnEnemypassed?.Invoke(); };
 }