Page 1 of 1

Save System - Day/Night Cycle

Posted: Fri Jul 17, 2020 4:29 am
by CruttMutt
Hey Tony,

I was wondering if you would have any suggestions to how I would enable to the save system to save the current state of my Enviro plug in to save the time of day/day#... ect. If can't quite wrap my head around the best way to do it or which component might work best. If I can get the values from the variables in the scripts, how can I have them saved so they can be re-read on load? Or can this not be done if it is not officially integrated?

Cheers!

Re: Save System - Day/Night Cycle

Posted: Fri Jul 17, 2020 7:29 am
by Tony Li
Hi,

Enviro isn't officially integrated, but it's just a matter of writing a Saver script and adding it to the scene. Make sure you've also set up the save system of course. To write a Saver script, copy the file Plugins / Pixel Crushers / Common / Templates / SaverTemplate.cs, rename it and move it outside the Plugins folder, and fill in the code where the comments indicate.

Re: Save System - Day/Night Cycle

Posted: Sat Jul 18, 2020 2:51 am
by CruttMutt
Thank you so much! This will come in handy for a lot of things.

Appreciate it!

Re: Save System - Day/Night Cycle

Posted: Sat Jul 18, 2020 8:03 am
by Tony Li
Glad to help!