Exemplo n.º 1
0
    private void Awake()
    {
        if (managerInstance != null)
        {
            GameSceneManager.Destroy(managerInstance);
        }
        else
        {
            managerInstance = this;
        }

        DontDestroyOnLoad(this);
    }