Unity scene keeps infinitely loading

I made a simple level select screen - when you press a button, it sends a signal to the game manager object to load a different scene

    public void LoadImmediate(int level)
    {
        SceneManager.LoadSceneAsync(level);
    }

The script is using UnityEngine.SceneManagement, and both the levels and menu scence are in the build settings.

How ever, when I press the button the scene doesn’t load once, but every few frames.
I can move the player a bit before the scene reloads, but then the player returns to the original position.
I added a debug.log line in the LoadImmediate function, but the message only appears once.

The hierarchy constantly switches between saying Lvl 1, and Lvl 1(is loading)

Find all references for SceneManager.LoadSceneAsync and SceneManager.LoadScene in your project code. Something tells me there’s a call somewhere in Awake or Start that keeps loading the scene again and again.

You need to safeguard this against repeated operation too!

Imagine the scene loads within 0.2s but since the loading is asynchronous, the buttons continue to function. Thus a player could spam the button and cause multiple reloads. Use the returned AsyncOperation object to add a callback to its completed event. For as long as the async operation isn’t completed or is non-null you wouldn’t allow another scene load.