public void OnSelectBackgroundPath(nfd.NfdResult r, string path, string[] paths) { if (r == nfd.NfdResult.NFD_OKAY) { config.backgroundTexturePath = path; TriggerChanges(Live2DViewerConfigChangeType.Background); Destroy(gameObject); } }
public void OnSelectRootFolder(nfd.NfdResult r, string path, string[] paths) { if (r == nfd.NfdResult.NFD_OKAY) { try { config.ScanFolder(path); TriggerChanges(Live2DViewerConfigChangeType.RootFolder); PlayerPrefs.SetString(ROOT_DIR_DEFAULT_PATH_PREF_KEY, path); Destroy(gameObject); } catch (Exception ex) { Debug.LogException(ex); } } }