I am currently trying to add custom data to save files. In my scene I have a custom camera controller for pixel perfect, scene bounds, and it controls a few other things.

I need to set a way to save custom data from the camera script example saving what was the last scene bounds so when I load a game it will restore the scene bounds from the last save state.

When going through the API I found in the save game handler there was a function called register custom data. Was wondering if anyone could give me an example of how to properly use it.

Basically just wanted to save a value in the save data. Also wondering when the game is loaded will the data from the object load automatically or is there another function I need to grab data from that custom save data.
  • Never mind, after looking through the documentation for 3 hours I found a link to a how to page I somehow missed that shows a code example. Ty for good documentation and lot's of examples.
  • For others who want to do something similar - there are 2 custom save systems:

    Custom Save Data allows you to add general save data, e.g. saving data from a weather system or other stuff you want to keep.

    Custom Component Save Data allows you to save additional stuff on a combatant.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.