How to Restart Level ?

Hello peeps!
I have a problem, before the script goes, it would give restart level when it hit an object. I’ve made some changes and now it’s not working the same way. I added tags to objects but I do not know what to do.

private void OnTriggerEnter2D(Collider2D Respawn)
    {
        if (Respawn.tag.Equals("Respawn"))

        {
            StartCoroutine("ReloadScene");
            Time.timeScale = 0f;
        }


        IEnumerator ReloadScene()
        {
            yield return new WaitForSecondsRealtime(0.5f);
            SceneManager.LoadScene("SampleScene");


        }

    }

Hi @tormentoarmagedoom , I did not write the code, I looked at youtube in the tutorial.
So, before the main object was to say “the player” was hitting the obstacle, the game was over. Now the player gets hit by the object, nothing happens, it just gets stuck in the object. I want to resume the scene when the player hits the object.
Excuse but I use google translations to express myself better.

Hi, this should fix it : Application.LoadLevel(Application.loadedlevel); just replace this with the SceneManager…

SOLVED

 private void OnTriggerEnter2D(Collider2D Player)
    {
        if (Player.tag.Equals("Respawn"))
            StartCoroutine("ReloadScene");
        Time.timeScale = 0f;
    }

    IEnumerator ReloadScene()
    {
        yield return new WaitForSecondsRealtime(0.5f);
        SceneManager.LoadScene("SampleScene");
    }

I believe its something like:

                UnityEngine.SceneManagement.SceneManager.LoadScene(UnityEngine.SceneManagement.SceneManager.GetActiveScene().name);