Help with reloading scene for endless runner

I have an endless running game with the traditional set up. Game starts, pans into Player, you press something on the screen to start the game. Now, I’m making the menu and was wondering what the usual practice is for this kind of game when you want to return back to the initial ‘Title area’ again (Eg. Subway Surfer spray-painting the train).
The most intuitive thing seems to be to simply use a single scene for the game and then just restart it.

I was wondering if I could get some thoughts on whether this sounds like the way to go or not.

Thanks

It would be easiest to have a separate scene for the main menu. You can use some fancy camera effects to hide the scene transition. This makes programming the game much more sane than moving the scene around to get to different parts. It will involve more loading time, but it will will make your life a lot less buggy.

Reloading a scene is probably the least developer work by far, but if your load times are long it’s going to degrade the user experience significantly.

Imagine if your game could restart in less than 100ms.

If you’re using object pools to manage your map objects, you can simply return all deployed objects to their pools (presumably this gets them out of sight), re-initialize the startup area as needed (move camera, re-spawn a few things, trigger animations and UI), and go from there. Your map generation is hopefully quick and cheap enough that generating a bit of map to start from isn’t a problem, or you can rely on a prefab to get that ball rolling.

If you’re not using pools, we’ve probably already thrown performance out of the window. :wink:

The above suggestion is going to be much easier to implement if you can separate those parts of your startup routine from Awake() and Start(), such that they can be called from those functions, but are not contained within them.