- 編集済み
Skin - Types
Hello together,
if I export a project to JSON, it works fine. I just want to know: in the skins section every attachment has a key "type". What different types of attachments exist?
I know there are "mesh" and "boundingbox". Are there some other types, and how can I configure them ?
Example:
"left-hand-item": {
"dagger": { "x": 7.88, "y": -23.46, "rotation": 10.48, "width": 26, "height": 108 },
"spear": {
"type": "mesh", // <
---
here is the type
"uvs": [ ... ],
"triangles": [ ... ],
"vertices": [ ... ],
"hull": 14,
"edges": [ .... ],
"width": 22,
"height": 368
}
}
Thank you,
David
You can find them documented here:
Spine: JSON export format: Attachments
It may be easier to just look at SkeletonJson code though. Are you writing JSON by hand?
Thank you for your response.
I already saw the documentation. this is everything to the types: "type: The type of attachment. Assume "region" if omitted."
No I want to convert the JSON-File to QML. The given QML-Converter on Github etc. are incompatible with the "new" json.files. The last thing what I need is to know what types are available. Because, in older JSON-Output-Files is a "skinnedmesh" type available. But, I don't know if it exits anymore and how I can configure it.
Immediately after the Common attachment attributes
section, the Attachment type
section lists all the types. After that the properties for each type are specified.
How can I be so blind?.......
Thank you!!
No worries, reading that document is certainly hard on the eyes! 8) As I mentioned, it'll be more pleasant to read the code:
spine-runtimes/SkeletonJson.java at 3.8
Please note that the JSON and binary formats had to change a bit in the next version (3.9). The code for that is in the 3.9-beta branch, but since we haven't released a 3.9-beta editor, there isn't currently a way to export data in the 3.9 format.
Thanks for the information. I will see what I have to do because of the 3.9 JSON export changes.