{"id":19382817,"url":"https://github.com/uisawara/unity-settingswitcher","last_synced_at":"2025-04-23T20:32:29.664Z","repository":{"id":55655201,"uuid":"200320400","full_name":"uisawara/unity-settingswitcher","owner":"uisawara","description":" Switch unity settings from a structured configuration file","archived":true,"fork":false,"pushed_at":"2020-12-14T23:54:11.000Z","size":502,"stargazers_count":1,"open_issues_count":7,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-24T17:14:52.943Z","etag":null,"topics":["unity","unity3d"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/uisawara.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-08-03T02:05:56.000Z","updated_at":"2024-11-01T05:08:57.000Z","dependencies_parsed_at":"2022-08-15T05:40:38.741Z","dependency_job_id":null,"html_url":"https://github.com/uisawara/unity-settingswitcher","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uisawara%2Funity-settingswitcher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uisawara%2Funity-settingswitcher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uisawara%2Funity-settingswitcher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uisawara%2Funity-settingswitcher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/uisawara","download_url":"https://codeload.github.com/uisawara/unity-settingswitcher/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250509864,"owners_count":21442513,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["unity","unity3d"],"created_at":"2024-11-10T09:23:26.164Z","updated_at":"2025-04-23T20:32:29.223Z","avatar_url":"https://github.com/uisawara.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"** Warning\n\n作成中につき各種仕様は変更の余地が多々あります.\n\n# unity-settingswitcher\n\n* データ駆動で Unity の各種設定 （BuildSettings, PlayerSettings, XRSettings等) をできるようにする Editor拡張です。\n* 名前付きで設定を定義して、それら設定を組み合わせて Unity設定を作ることができます。\n\n概念図\n\n![Screen Shot 2019-12-13 at 16 06 08](https://user-images.githubusercontent.com/4578728/70777373-ea4d0b00-1dc2-11ea-944c-fc4d78ce8948.png)\n\n設定例と設定切替Window\n\n![Screen Shot 2019-12-13 at 16 08 22](https://user-images.githubusercontent.com/4578728/70777368-e6b98400-1dc2-11ea-8d14-d96432bb95fe.png)\n\n* 設定ファイルでは名前付きで設定(Setting)を定義します。\n* SettingではUnityの各種設定(BuildSettings, PlayerSettings, XRSettings)にセットする値を定義します。\n* 可能なこと\n    * 他Settingを継承したSettingの定義\n    * Settingのグループ分け\n    * SettingSwitcherウィンドウからのSetting切替\n    * Settingの有効・無効の切替\n    * SwttingSwitcherウィンドウのSettingリストへ非表示なSettingの定義\n    * 複数設定ファイルでの設定定義(v0.0.4)\n\n* ※Settingは他のSettingの設定を継承(inherit)して差分設定を作ることができます。\n* ※Setting名は\"/\"で区切ることでグループ化することができます。（現在のところグループは１階層のみ）\n* ※各グループ内で選択してアクティブにできる設定は１つのみ\n\n## 利用例\n\n- PC向けとVR向け、develop向けとproduction向けを切り替える。\n\n例)\n![unity-settingswitcher-sample](https://user-images.githubusercontent.com/4578728/62419417-8438d480-b6ba-11e9-8c12-69abba41261e.png)\n* 設定例\n    * PC用設定を継承したWindows64向け設定とDevelop向け設定をマージしたものをUnityへ反映する\n    * VR用設定を継承したSteamVR向け設定とProduction向け設定をマージしたものをUnityへ反映する\n\n\n## 開発環境\n\n* Unity 2018.4.12f (他バージョンのUnityは未検証)\n* MacOSX Catalina Version 10.15.1\n\n## 使いかた\n\n### Unity PackageManager版\n\n- 導入\n  - Packages/manifest.jsonへ以下を追記します。\n```\n{\n  \"dependencies\": {\n    \"work.mmzk.libs.minijson\": \"https://github.com/uisawara/unity-minijson.git\",\n    \"work.mmzk.libs.unitysettingswitcher\": \"https://github.com/uisawara/unity-settingswitcher.git\"\n  }\n}\n```\n\n- 初期設定\n  - UnitySettingSwitcherウィンドウを開く。(Window-\u003eUnity Setting Switcherを選択か、CMD+E)\n  - Packages/UnitySettingSwitcher/Templates/settings/Settings.jsonをAssets/へコピーする\n  - Assets/Settings.jsonをテキストエディタ等で編集して設定を定義する\n\n### unitypackage版 (deprecated / いずれPackageManagerのみになります)\n\n- 導入\n  - MiniJSONが必要です (https://gist.github.com/darktable/1411710)\n\n## ファイル構成\n\n### ディレクトリ構成\n\n/\u003cAssets\u003e\n\tsettings.json .. 設定定義ファイル\n\tsettingsselected.local.json .. 選択されている設定を保存しているファイル\n\n### settings.json JSON構造\n\n- settings : array\n  - name : string .. 設定名\n  - scene_list : array\u003cstring\u003e\n    - シーンファイル(.scene)パス\n  - player_settings : object\n    - 設定キー名(UnityのBuildSetting等該当クラスのpublic-staticメンバ名) : 値(string,bool,int,floatのみ対応)\n  - xr_settings : object\n    - keyValues : ※player_settings同様\n\n- 設定名\n  - \".\"で始まっているとUnitySettingSwitcherウィンドウの設定一覧上に非表示になる。\n- player_settings\n  - UnityのPlayerSettingsクラスに対しての設定値\n- xr_settings\n  - UnityのXRSettingsクラスに対しての設定値\n\n## 補足\n\n- 設定の結合ルール\n  - 設定は、グループごとの選択中な設定を結合したもの\n- 設定の結合順序\n  - 選択されている設定の定義されている順\n  - 継承構造の子側から親側に順次\n- JSONで記述された設定はC#のリフレクションを用いてBuildSettingsクラス等のpublic staticメンバーへ反映している。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuisawara%2Funity-settingswitcher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuisawara%2Funity-settingswitcher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuisawara%2Funity-settingswitcher/lists"}