I am looking for a way to activate a mode (easy / difficult) before loading the scene.
My scene has such a structure, that there is three packs of GameObjects:
- All the stage gameObjects
- Easy mode gameObjects
- Difficult mode gameObjects
I was expecting to do something like “Application.load(0)” (“0” meaning “easy mode” for example)
Does someone know how I can do it?
There are two potential solutions I see to this problem:
- Store the difficulty in PlayerPrefs, when your level loads read PlayerPrefs to see what difficulty to setup.
- Use DontDestroyOnLoad to keep your difficulty objects through the scene transition.
What do you mean by “keep your difficulty objects through the scene transition”? My difficulty objects are bigger monsters or smaller bonuses, for example. I can’t “keep” it anyhow because they only exist in the game scene…