Hello,
Im currently working on an inventory system and would like to save the inventories contents at runtime and load the saved contents on new startup of a Standalone / Android / iOS build.
Question: Can this be achieved via Scriptable Objects? Or do I have to create a custom serialization/deserialization/load configurations system on my own?(hope not)
Additional Info: Im planning to use instaces of scriptableobjects to handle an item’s behaviour. It would be great if overriding those instances would be possible somehow. Otherwise i think a better solution would be to use scriptableobject instances just as item prefabs and load those via ID from custom serialization.
No, I’m not going to use Playprefs 
Thanks in advance,
Apprentice
Found a quick way for saving on local harddrive.
using UnityEngine;
using System.Collections;
using System;
using System.Runtime.Serialization.Formatters.Binary;
using System.IO;
[System.Serializable]
public class SaveGame
{
[SerializeField]
public Inventory inventory;
public static int SaveSlot = 0;
public SaveGame ()
{
inventory = new Inventory ();
}
public void Save ()
{
FileStream myStream;
string savep = Application.dataPath + "/SavedGames/SaveGame" + SaveSlot.ToString () + ".saveGame";
myStream = new FileStream (savep, FileMode.Create);
BinaryFormatter binFormatter = new BinaryFormatter ();
binFormatter.Serialize (myStream, this);
myStream.Close ();
}
public static SaveGame Load ()
{
SaveGame oldObj;
BinaryFormatter binFormatter = new BinaryFormatter ();
string directory = Application.dataPath + "/SavedGames/";
string savep = directory + "SaveGame" + SaveSlot.ToString () + ".saveGame";
if ((directory.Length > 0) (!Directory.Exists (directory))) {
Directory.CreateDirectory (directory);
}
FileStream fs;
try {
fs = new FileStream (savep, FileMode.Open);
if (fs != null) {
oldObj = (SaveGame)binFormatter.Deserialize (fs);
return oldObj;
}
} catch (FileNotFoundException e) {
Debug.Log ("There is no savegame!! " + e.Message);
}
return null;
}
}
To make it work all referenced instances(inside savegame class, e.g. Inventory class) that need to be saved have to use [System.Serializable] above class definition and [SerializeField] on above any field that you want to store?
Edit: Is there maybe a way around the try catch?