- Home /
Save Integer Values
How can integer values be saved?
Comment
Answer by phodges · Oct 21, 2012 at 08:04 PM
It would be better if you could be more specific. I'm going to guess that you want to save some sort of player property between sessions, if that's true then take a look at PlayerPrefs
http://docs.unity3d.com/Documentation/ScriptReference/PlayerPrefs.html
It has Get and Set methods for integers and other values.
When the game is quit, integer values that aren't preset are reset. I would like to save those values.
So does my answer cover your needs? Are you saving, larger more complex state? Do you need a separate store per variable?
I think that phodges means that you can save the int into PlayerPrefs when the Value change.