Ok, so I’m not sure on how I should do this:
I have a project with a custom 2D animator system and I need to load the sprites, they are currently neatly organized each animation in a folder for each character, example:
Resources/Paladin/Attack
Resources/Paladin/Idle
Resources/Paladin/Walk
Resources/Mage/Attack
Resources/Mage/Idle
Resources/Mage/Walk
Using the Resources.Load system I can just load Paladin/Attack and get all it’s sprites, I can change the sprites freely and without any need of updating anything in the project or code. But doing the same with Adressable Assets is not being that easy, I found 3 possible solutions.
-
Serialize the sprites into a .prefab and use the addressable system to load the prefab instead of the sprites. Though this doesn’t allow me to change sprites freely without hassle.
-
Renaming the addresses. As stated by one of the devs, the addresses do not need to be unique, if more than one have the same name, I can load them all with only that one address. The problem is, I cannot find a way to rename multiple addresses quickly, I can only go one by one and "ctrl+v"ing that address. This really sounded like the proper solution, but ends up being a bigger hassle and even harder to update, unless there is some other way of doing this that I’m unaware of(please teach me if there is).
-
Labels, with this I can accomplish what I tried to do in 2), though the way the UI looks, it’s almost screaming that I’m using this wrong. Since I’ll have many units and animations I’ll end up with a ton of labels, not sure if there is a limit or if it should be even used for this. With them I can just mark a Folder with that label and load it hassle free, using it as an “open assetBundle”.
So…am I using labels wrong? Is there a way to quickly change all addresses in a directory? Would it be possible to have a way to load all sprites in a specific addressable folder? Maybe something else entirely that I missed?