{"id":13662422,"url":"https://github.com/Haruma-K/EZAddresser","last_synced_at":"2025-04-25T10:31:18.479Z","repository":{"id":42456847,"uuid":"332417193","full_name":"Haruma-K/EZAddresser","owner":"Haruma-K","description":"Automatic addressing system for Unity Addressable Asset System.","archived":false,"fork":false,"pushed_at":"2023-04-26T02:51:44.000Z","size":436,"stargazers_count":161,"open_issues_count":0,"forks_count":7,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-11-09T22:42:19.469Z","etag":null,"topics":["addressable","addressables","unity"],"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/Haruma-K.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2021-01-24T10:10:52.000Z","updated_at":"2024-11-05T17:26:18.000Z","dependencies_parsed_at":"2024-01-11T13:19:38.882Z","dependency_job_id":null,"html_url":"https://github.com/Haruma-K/EZAddresser","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Haruma-K%2FEZAddresser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Haruma-K%2FEZAddresser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Haruma-K%2FEZAddresser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Haruma-K%2FEZAddresser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Haruma-K","download_url":"https://codeload.github.com/Haruma-K/EZAddresser/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223996602,"owners_count":17238336,"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":["addressable","addressables","unity"],"created_at":"2024-08-02T05:01:58.235Z","updated_at":"2024-11-10T18:30:24.485Z","avatar_url":"https://github.com/Haruma-K.png","language":"C#","readme":"\u003e **Warning**  \n\u003e My company has released a more sophisticated tool called [Smart Addresser](https://github.com/CyberAgentGameEntertainment/SmartAddresser), so I recommend using it instead.\n\u003e This tool will not be archived, but there are no plans for active improvements.\n\n\u003ch1 align=\"center\"\u003eEZAddresser\u003c/h1\u003e\n\nEZAddresser is automatic addressing system for Unity Addressable Asset System.  \nYou can load assets in very simple two steps:\n\n1. Put the asset you want to load into the \"Addressables\" folder.\n2. Call `Addressables.LoadAssetAsync(\"[asset name here]\")`.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/47441314/105809345-de370380-5fec-11eb-84fb-e1511e653b0b.gif\" alt=\"Sample\"\u003e\n\u003c/p\u003e\n\n## Setup\n#### Requirement\nUnity 2020.1 or higher (because of generic type serialization).\n\n#### Install\n1. Open the Package Manager from Window \u003e Package Manager\n2. \"+\" button \u003e Add package from git URL\n3. Enter the following\n    * https://github.com/Haruma-K/EZAddresser.git?path=/Packages/com.harumak.ezaddresser\n\n\u003cp align=\"center\"\u003e\n  \u003cimg width=500 src=\"https://user-images.githubusercontent.com/47441314/113792801-c1077980-9781-11eb-8770-210999a25c9a.png\" alt=\"Package Manager\"\u003e\n\u003c/p\u003e\n\n\nOr, open Packages/manifest.json and add the following to the dependencies block.\n\n```json\n{\n    \"dependencies\": {\n        \"com.harumak.ezaddresser\": \"https://github.com/Haruma-K/EZAddresser.git?path=/Packages/com.harumak.ezaddresser\"\n    }\n}\n```\n\nIf you want to set the target version, specify it like follow.\n* https://github.com/Haruma-K/EZAddresser.git?path=/Packages/com.harumak.ezaddresser#0.1.0\n\n#### License\nThis software is released under the MIT License.  \nYou are free to use it within the scope of the license.  \nHowever, the following copyright and license notices are required for use.\n\nhttps://github.com/Haruma-K/EZAddresser/blob/master/LICENSE.md\n\n## Getting Started\nYou can load the assets with EZAddresser by following steps:\n\n1. Create a folder named \"Addressables\".\n2. Store the assets you want to load in the \"Addressables\" folder.\n3. Call Addressables.LoadAssetAsync([file name]) to load them.\n\nIn this process, addresses and groups are created according to the following rules.\n\n1. Addresses will be created to match the file name without extension. (This can be changed, see below.)\n2. Multiple \"Addressables\" folders can be created and folders can be nested together.\n3. the AssetBundle will be split per \"Addressables\" folders. (This can be changed, see below.)\n\n## Global Settings\nYou can edit the global settings from Window \u003e EZAddresser \u003e Settings.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/47441314/105818382-345e7380-5ffa-11eb-94a3-e98657967a0f.png\" alt=\"Global Settings\"\u003e\n\u003c/p\u003e\n\nThe description of each setting item is as follows.\n\n|Item Name|Description|\n|-|-|\n|Base Packing Mode|\u003cb\u003ePack By Addressables Folder\u003c/b\u003e: AssetBundle is split according to the \"Addressables\" folder.\u003cbr\u003e\u003cb\u003ePack Together\u003c/b\u003e: All assets are stored in the same AssetBundle.|\n|Base Addressing Mode|\u003cb\u003eAsset Name\u003c/b\u003e: File names with extensions are used for addresses.\u003cbr\u003e\u003cb\u003eAsset Name Without Extensions\u003c/b\u003e: File names without extensions are used for addresses.\u003cbr\u003e\u003cb\u003eAddressable Path:\u003c/b\u003e Relative paths from the \"Addressables\" folder with extensions are used for addresses.\u003cbr\u003e\u003cb\u003eAddressable Path Without Extensions:\u003c/b\u003e Relative paths from the \"Addressables\" folder without extensions are used for addresses.|\n|Group Template|Template used to create a group.\u003cbr\u003eIf not set, the first template set in AddressableAssetSettings will be used.|\n\nWhen you change these setting items, the following dialog will appear and all addresses and groups will be updated.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/47441314/105822625-a4bbc380-5fff-11eb-80e6-929ed446d915.png\" alt=\"Dialog\"\u003e\n\u003c/p\u003e\n\nNote that when you change the Group Template, all groups will be deleted once and the settings for each group will be reset.\n\n## Per Asset Settings\nYou can edit the per asset settings from Window \u003e EZAddresser \u003e Entry Rule Editor.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/47441314/106751584-bab72d00-666c-11eb-9d26-55d85a66419a.png\" alt=\"Per Asset Settings\"\u003e\n\u003c/p\u003e\n\nYou can create a new rule from the Create button on the toolbar.  \nThe description of each setting item is as follows.\n\n|Item Name|Description|\n|-|-|\n|Addressable Path Rule|Regular expression representing the relative path of the target asset from the Addressables folder.|\n|Addressing Mode|Addressing Mode to be applied to the target asset.|\n|Group Name Rule|Group name to which the target asset belongs.\u003cbr\u003eThe actual group name is retrieved with `Regex.Replace([Addressable Path], [Addressable Path Rule], [Group Name Rule])`.\u003cbr\u003eHowever, '/' is replaced by '-' because it is not an appropriate group name.|\n|Label Rule(s)|The name of the label to attach to the target asset.\u003cbr\u003eThe actual label is retrieved with `Regex.Replace([Addressable Path], [Addressable Path Rule], [Label Rule])`.\u003cbr\u003eMultiple labels can be defined by separating them with commas.\u003cbr\u003eSpaces are not allowed in label names.|\n\nFor example, if you set the Addressable Path Rule as prepub_sample_(?\u003cprefab_id\u003e[0-9]{3})\\.prefab, then\nBoth prefab_sample_001.prefab and prefab_sample_002.prefab will be subject to this rule.\nAnd if you set the Group Name Rule of this rule as Prefab${prefab_id}, the above Prefabs will be stored in the groups Prefab001 and Prefab002 respectively.\n\nIf you change any of these settings, the following dialog will appear and all addresses and groups will be updated.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/47441314/105823884-11838d80-6001-11eb-996b-d62a962082f2.png\" alt=\"Dialog\"\u003e\n\u003c/p\u003e\n\n## Assumed Workflow\nEZAddresser is designed assuming the following workflow.\n\nThe first thing to think about is the prototype or early stage of the project.\nAt this time, it's enough to have all the resources built into the app, and you don't need to think about how to divide the AssetBundle.\nTherefore, you can just throw the resources you want to load into the Addressables folder without thinking about the details.\nBut you may want to decide only the Base Addressing Mode in Settings.\n\nAs the project progresses, a resource delivery server will be prepared to download resources.\nAt this point, you will set up Content Packing \u0026 Loading for each group using the Addressalbe asset system features.\nAlso, if you want to change the template for a group, it is recommended to do so at this point.\n\nAnd as the project gets closer to completion, one of the issues that often comes up is the division unit of the AssetBundle.  \nMost of the time, you will need to split an asset bundle that is too large into appropriate granularity.  \nAt this point, you can use the Entry Rule Editor to store the assets into the appropriate AssetBundle.\n\n## Operate programmatically\nGlobal settings and per-asset settings can be operated programmatically.\n\nThe global settings can be operated as follows.\n\n```cs\nvar settingsService = new SettingsService(new SettingsRepository());\nsettingsService.UpdateSetting(packingMode, addressingMode, groupTemplateGuid);\nsettingsService.Save();\n```\n\nPer asset settings can be operated as follows.\n\n```cs\nvar entryRulesService = new EntryRulesService(new EntryRulesRepository());\n\n// Get all rules.\nvar allRules = entryRulesService.GetState();\n// Get the first rule.\nvar firstRule = allRules.First();\n// Update the first rule.\nentryRulesService.UpdateRule(firstRule.Id, new EntryRuleUpdateCommand(addressablePathRule, addressingMode, groupNameRule));\n// Add rule.\nentryRulesService.AddRule(new EntryRuleUpdateCommand(addressablePathRule, addressingMode, groupNameRule));\n// Remove Rule.\nentryRulesService.RemoveRule(firstRule.Id);\n// Save changes.\nentryRulesService.Save();\n```\n","funding_links":[],"categories":["Unity","C\\#","Open Source Repositories","C#"],"sub_categories":["Lua","Asset Bundle / Addressable Assets"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FHaruma-K%2FEZAddresser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FHaruma-K%2FEZAddresser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FHaruma-K%2FEZAddresser/lists"}