How to link scenes and update datas and statuses from one scene to another?
Say, from your main menu, to ingame, from load game to ingame menus and so on?
How to link scenes and update datas and statuses from one scene to another?
Say, from your main menu, to ingame, from load game to ingame menus and so on?
You should use playerprefs,in episode 6 of my series ,you find the link to my channel in my signature I use player prefs to carry the number of coins accross scenes,If you want to change scene you can use unIty scene manager
![]()
save the data somewhere like a json file or player prefs, or you put that data on a object marked with DontDestroyOnLoad which will let that object live through scene changes
You could also store all the data shared between scenes on a unique GameObject that you would tagged with
This method is used effectively to have the object to persists while changing scene.
Thanks for the reply! I forgot to subscribe to all the threads…this is all so frustating…
I particularly like the Object.DontDestroyOnLoad but i change from scenes to scenes, 2d to 3d, ui to ingame so i’m not sure what to mark my gameobject as? Like wil there be an object “Player” from the start of main menu, or “options”, “data” as i load from main menu to ingame inventory screen?