GameObjects Still there after PhotonNetwork.LoadLevel

Options
Hello, i have following problem: in my game-scene are 2 Players(with Photonview); when one of them dies they go back to the main menu with PhotonNetwork.LoadLevel but somehow the 2 Players also appear in the main menu. Shouldnt PhotonNetwork.LoadLevel destroy all objects in the "old" scene?

Comments

  • Clyon
    Options
    okay solve it by adding this to the players:

    private void OnSceneLoaded(Scene scene, LoadSceneMode mode)
    {
    if (scene.name == "Menu")
    {
    Destroy(gameObject);
    }
    }