Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Splitting the menu and game into different files, is this the correct solution?

Discussion in 'Editor & General Support' started by The-Little-Guy, Jun 8, 2018.

  1. The-Little-Guy

    The-Little-Guy

    Joined:
    Aug 1, 2012
    Posts:
    297
    What is the best way to do this?

    I have 3 scenes "Main", "Game", "Menu". Main is the scene that loads, it then loads Game and Menu using:

    Code (CSharp):
    1. SceneManager.LoadScene("Menu", LoadSceneMode.Additive);
    2. SceneManager.LoadScene("Game", LoadSceneMode.Additive);
    Once loaded I want to default to the menu, and when the player clicks "Play" the camera would pan to the game.

    Is splitting the menu and the game into different scenes the correct solution for this?
     
  2. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    Not sure what you mean by "default to the menu". When you load scenes additively they are all running at the same time. But you're certainly free to pan your camera around so it can view the various objects you've included in any of those scenes.

    You can open multiple scenes in the editor at the same time as well, which will show you what it will look like.