00:00
00:00
Newgrounds Background Image Theme

Someone gifted MetalSlayer69 supporter status!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

Edits to post #27061401 by RaIix

Edited

At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references. In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0 again.


At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references. In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0 again (and again, and again…).

Edited

At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references. In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.


At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references. In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0 again.

Edited

At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references.

In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.


At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references. In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.

Edited

At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time.

In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.


At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time, and breaks references.

In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.

Edited

At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself in every scene, which takes time.

In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.


At 10/15/21 03:24 PM, GraeBush wrote: I also prefab'd everything and added it to each scene. Should I only use one instance of the NGio and carry it over with a Singleton like you suggested?


That's much better, because then it doesn't have to initialize itself again in every scene, which takes time.

In my project, I just initialize it in the menu and run DontDestroyOnLoad on it and keep it forever (and use it when needed).


Also, with your current code, I believe every scene would now send you back to Scene 0.