public static void Save(PortesArmari portesArmari) { string jsonPath = Application.persistentDataPath + "/portesArmari.json"; PortesArmariData data = new PortesArmariData(portesArmari); string json = JsonUtility.ToJson(data); File.WriteAllText(jsonPath, json); Debug.Log("Save " + json); }
public PortesArmariData(PortesArmari portesArmari) { index = portesArmari.index; }