how does PlayerPref "save" work?

I was able to store my first data 10 minutes ago and I’m glad I solved this “frightening” thing. For me it was a scary thing.

Now I read about the “save” command: Writes all modified preferences to disk.

Ummm… What does that mean exactly?

  1. Does it save all stored values in one?
  2. Which way I call up that command?
  3. Is it watching all values permanently if they change?

I think, since PlayerPrefs is in itself a class, Save() will save all PlayerPrefs, regardless of script. That being said, I Save() at convenient points in various scripts. By convenient I mean, where not much action is happening on the engine.

  1. yes, not 100%, but it would make sense that one PlayerPrefs.Save(); will save any PlayerPrefs value in the project.

  2. ex. HiScore = PlayerPrefs.GetFloat(“hiScore”);

  3. no. PlayerPrefs is not observing anything. You set a value, save a value and retrieve a value. That’s it.

Thank You to Canada :wink:

LoL