• Editor
  • Using Spine CLI on a back-end server

We have a need to export some Spine Assets on demand. I know the server needs to have OpenGL, but wondering if there is anything in the license or in the feature that might block us from putting Spine on an EC2 box we own (persistent), and using that as a server to generate some assets and store them in S3.

Spine Professional and Essential are licensed to a single named person, so they aren't suitable for running on a server or any other kind of shared access.

We have an option for Spine Enterprise where we can provide an activation code solely for CLI usage. This is typically used in build processes, but probably could be used by a server to perform exports on the fly, if somewhat slowly.

Maybe we can help more if you explain more about what you want to do? It's unusual for a server to need to do exports, unless it's a build server. Skeletons can be customized at runtime without needing to manipulate skeleton data.

We want to switch our Skeleton's weapon at runtime but couldn't figure out the right way to do it.

The problem is this weapon image is generated on the fly via an image generator so (if I understand correctly) it can't be put as an attachment in the slot where the weapon would otherwise be in the Spine project. I saw in the Spine tutorials with the goblin they change from a staff to a dagger by switching the attachment ( Perhaps I can still do this with the image even if the image/attachment is not included in the original Spine file? I saw this tutorial from a while ago:

In addition, each user in our game has a unique random generated weapon image for that specific character (it's a turn based strategy game so they are like Fire Emblem units). We would store the generated .atlas.txt, .json, and .png and at runtime I was able to assemble this into a SkeletonDataAsset + SkeletonDataAtlasAsset and have it work correctly, but the final step is making the Spine export process after generating the image of the weapon, which I am working on now.

Spine doesn't require all attachments to be created in the editor. Attachments can be created at runtime:
http://esotericsoftware.com/spine-runtime-skins#Creating-attachments

There are examples in spine-unity showing how to do this.

You can use attachments defined in the editor as a template to create attachments at the same location at runtime.

Thank you! I will give that a shot. I mistakenly thought Skins were a build and import time only feature because the Unity Spine runtime editor has a lot of post processing on the assets.

You're welcome! Let us know if you run into trouble or have questions.

Skins are just a collection of attachments. Attachments have the data they need (position, vertices, etc) and are separate from the image used to render them. The attachment loader is the mechanism which configures an attachment with the image for rendering. That can be customized, for example to not load any image, then configure it later.

@vishaalk Please have a look at the example scenes Spine Examples/Other Examples/Mix and Match and Mix and Match Equip regarding using Unity Sprites.

Note that there is also a video available about the spine-unity example scenes: