{"id":15160634,"url":"https://github.com/persomatey/unityjsonserializerplugin","last_synced_at":"2026-02-21T22:31:34.484Z","repository":{"id":140065829,"uuid":"533089671","full_name":"Persomatey/UnityJSONSerializerPlugin","owner":"Persomatey","description":"A JSON serializer package for Unity which supports reading from and writing to JSON files. ","archived":false,"fork":false,"pushed_at":"2023-03-06T00:02:27.000Z","size":640,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-07T20:12:40.967Z","etag":null,"topics":["unity","unity-package","unity-packages","unity-plugin","unity2d","unity2d-package","unity2d-packages","unity2d-plugin","unity3d","unity3d-package","unity3d-packages","unity3d-plugin"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Persomatey.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-09-05T23:20:57.000Z","updated_at":"2024-04-05T11:31:33.000Z","dependencies_parsed_at":null,"dependency_job_id":"36b8b13a-8952-46b2-9feb-6e8a77ef988f","html_url":"https://github.com/Persomatey/UnityJSONSerializerPlugin","commit_stats":{"total_commits":25,"total_committers":1,"mean_commits":25.0,"dds":0.0,"last_synced_commit":"65e2270239e4be10a613311881fc0ef936bb245e"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Persomatey%2FUnityJSONSerializerPlugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Persomatey%2FUnityJSONSerializerPlugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Persomatey%2FUnityJSONSerializerPlugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Persomatey%2FUnityJSONSerializerPlugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Persomatey","download_url":"https://codeload.github.com/Persomatey/UnityJSONSerializerPlugin/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247721899,"owners_count":20985084,"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","unity-package","unity-packages","unity-plugin","unity2d","unity2d-package","unity2d-packages","unity2d-plugin","unity3d","unity3d-package","unity3d-packages","unity3d-plugin"],"created_at":"2024-09-26T23:04:37.410Z","updated_at":"2025-10-27T04:15:34.306Z","avatar_url":"https://github.com/Persomatey.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Unity JSON Serializer Plugin \n\u003ci\u003eA JSON serializer plugin for Unity which supports reading from and writing to JSON files. \u003c/i\u003e\n\nCheck out [releases](https://github.com/Persomatey/JSONSerializerPlugin/releases) to download the unity package. \n\n\u003cimg src=\"https://raw.githubusercontent.com/Persomatey/UnityJSONSerializerPlugin/main/Logo/JSONSerializerPluginLogo.png\" width=\"318\"/\u003e\n\n## Tutorial \n\u003cdetails\u003e\n\u003csummary\u003eTutorial\u003c/summary\u003e\n\n### Setup\nSince everything in this plugin is wrapped in a JSON namespace, you'll need to add it at the top of your script. \n```\nusing JSON; \n```\n\nBecause .json files are read as TextAssets in Unity, you'll need a reference to the TextAsset in your script like so: \n```\n[SerializeField] TextAsset file;\npublic TextAsset file;\n```\n---\n### Creating a new JSON object from a file \nCall the constructor, using the TextAsset you want read in the parameters. \n```\nJSON myJSON = new JSON(file);\n```\nThere is also a constructor for if you don't have a parameter. \n```\nJSON myJSON = new JSON();\n```\n---\n### Serializing JSON object to a file \nYou can serialize the JSON object to the provided TextAsset file. \n```\nwriteJSON.WriteToFile();\n```\nIf no parameter was provided when object was created, you'll need to include the TextAsset in the parameters of `WriteToFile()`\n```\nwriteJSON.WriteToFile(file);\n```\n---\n### Reading, writing, and removing JSON variables  \nTo read a specific variable (`GetBool`, `GetInt`, `GetFloat`, `GetString`): \n```\nmyJSON.GetString(\"myStr\"); \n```\nTo change a specific variable (`SetBool`, `SetInt`, `SetFloat`, `SetString`): \n```\nmyJSON.SetInt(\"myInt\", 246); \n```\nTo add a variable to the JSON (`AddBool`, `AddInt`, `AddFloat`, `AddString`): \n```\nmyJSON.AddFloat(\"myFloat\", 24.68); \n```\nTo remove a variable from the JSON (`RemoveBool`, `RemoveInt`, `RemoveFloat`, `RemoveString`)\n```\nmyJSON.RemoveBool(\"myBool\"); \n```\n---\n\u003c/details\u003e \n\n## Details \n\n\u003cdetails\u003e\n\u003csummary\u003eSpecs\u003c/summary\u003e\n\u003cblockquote\u003e\n\t\nUnity 2020.3.32f1\n- Windows: https://download.unity3d.com/download_unity/12f8b0834f07/UnityDownloadAssistant-2020.3.32f1.exe \n- Mac: https://download.unity3d.com/download_unity/12f8b0834f07/UnityDownloadAssistant-2020.3.32f1.dmg \n- Unity HUB: unityhub://2020.3.32f1/12f8b0834f07 \n\nSLN solution in Visual Studio Community 2019 Preview \nhttps://visualstudio.microsoft.com/vs/community/\n\t\n\u003c/blockquote\u003e\n\u003c/details\u003e \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpersomatey%2Funityjsonserializerplugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpersomatey%2Funityjsonserializerplugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpersomatey%2Funityjsonserializerplugin/lists"}