Hello all!
So I have this spine skeleton with multiple skins, where the images are within subfolders.
And from my understanding, one way is to simply create an animation group with the path name, and insert the image inside (making the JSON reference correct).
Doing a single or a couple of images, isn’t really an issue, but in this case I have approx 25*7 separate images, so I’m wondering is there a method or any ideas of making that process… Less… 
I realize worst case scenario I’ll either have to rename the files and chunk them into a single folder, OR do the animationgroup thing…
As I’m typing this, perhaps a small script that would rename the files (giving them the path names , since I have multiple images with the same name i.e body.png, head.png etc)…
But then that creates another problem, which is the json reference, so I would have to add each part in it’s placeholder again…
Any ideas as much appreciated
All the best,
Alfredo
Some options
- Manually do it
- Con: Would take hours
- Con: (Human) Error prone
- Con: Need to keep doing it
- Open the exported Json file in a text program and search your folders (i.e. ) “main/stickfigure_images/” and replace it with “” (nothing). Then you can add all images as you normally do to an atlas.
- Con: Can’t have images that share name
- Con: Need to keep doing it
- Pro: Quick
- Create your atlas with a script.
- Con: Can’t add things manually to the atlas later
- Con: Need to keep running it
- Put all images in the same folder in Spine, if they share name use prefix’s
- Con: Not as easy to get an overview
- Pro: No need to keep running scrips/search and replace
- Pro: It just works.
I would go with number 4. - This is such a “minor” thing and I don’t see a reason to make it more complex than necessary.
3 Likes
Thanks for the options! So I solved this in a another way that I thought I’d share in case someone else is stuck in the same situation.
EDIT: My bad! this is exactly your option #4 
The overview:
I gathered all the images, and added the foldername as a prefix (body.png became arsenal_body.png etc), and then put them all into the same folder.
I did that by creating a powershell script that looped through each folder, parsed the names, added prefix and moved them into a new folder. (Glad I didn’t have to move, rename and add prefix 300 images by hand).
(Google powershell scripting, super easy and perfect for these type of things)
Then I opened the spine project and just dragged every image into it’s placeholder, that became easy since they had the same name (- the prefix), so that was the only manual part that took about 30 minutes to drag and drop.
(I’m sure a small script could have done the trick, but I rather have the spine project correctly setup in case I have to make changes later on)
And after that, just re-export, and worked like a charm 
Again, many thanks the answer and the many options!
2 Likes