private void LoadPrefData(bool saveOnharddrive = true) { PreferenceSave toLoad = new PreferenceSave(); string loaded = UnityDirectoryStorage.LoadFile("JavaOMI", m_prefId + ".txt", saveOnharddrive); if (loaded == null || loaded == "") { return; } toLoad = JsonUtility.FromJson <PreferenceSave>(loaded); if (toLoad == null) { return; } m_autoStart.isOn = toLoad.m_autoStart; m_name.text = toLoad.m_threadName; m_port.text = "" + toLoad.m_port; m_ip[0].SetIndex(toLoad.m_ip[0]); m_ip[1].SetIndex(toLoad.m_ip[1]); m_ip[2].SetIndex(toLoad.m_ip[2]); m_ip[3].SetIndex(toLoad.m_ip[3]); }
private void OnEnable() { SetUnicodeChars(UnityDirectoryStorage.LoadFile("JavaOMI", "UnicodePrefList.txt", m_saveOnHarddrive)); Refresh(); }
private void Start() { SetUnicodeChars(UnityDirectoryStorage.LoadFile("JavaOMI", "UnicodePrefList.txt", m_saveOnHarddrive)); Invoke("Refresh", 0.1f); Refresh(); }