Hey, I have a harder problem:
Using System.IO, is it possible to have instances of a prefab create custom keys (eg prefabName_number_variable) and then somehow search for the keys and reload their values at runtime?
Ideally, it would work like this:
At runtime, if prefabName_id_variable : Key exists, read it. Else, create it.
As prefabName_id_variable changes, write the new value to an .xml, .txt, etc.
Now I can probably use something like
var prefabName : String = “CubePrefab”;
var instanceNumber : int = 3;
var customKeyForHealth : String = prefabName + “" + instanceNumber.ToString() + "” + “health”;
which would yield “CubePrefab_3_health” which is great, but how would I search out the key from the .xml, .txt, etc.? PlayerPrefs has funcitonality similar to this, but as far as I know there is very limited control over how many PlayerPrefs files there can be and where they are in the system. With custom .xml or .txt files for save games I can control the number and location of them.
Any help would be greatly appreciated, since this concept is pivotal to a good save game system.