Пример #1
0
    public void LoadData()
    {
        exampleData.ignoreMe = Random.Range(0, 100);
        var i = exampleData.ignoreMe;

        exampleData = jsonSaveLoad.LoadObject <ExampleJsonData>("example");
        Debug.Log("After loading, value of ignored variable:" + exampleData.ignoreMe + " changed from: " + i);
        Debug.Log("The value of the ignored variables should be same as the default values defined in class");
    }
Пример #2
0
    // Use this for initialization
    void Start()
    {
        configUI.clear();

        jsonSaveLoad.folderPath = "./";
        jsonSaveLoad.isRelative = false;

        var configStore = jsonSaveLoad.LoadObject <ConfigVarStore>("config", false);

        configUI.store = configStore;

        configUI.GenerateUI();
    }