- Editado
Issue with importing Spine to Game Maker Studio
Hello everyone,
I exported as json the two Spine boy projects given in version 1.7 and 3.2 of Spine using the latest version.
I mean the old spine boy with the grey pants and the new one that is cyberpunk. To be exact the second was the
Spineboy-mesh, that uses the hoverboard.
For both I used the same settings.
The old spine boy is imported well in Game Maker Studio.
The new one gives me this error
Requested value 'weightedmesh' was not found.
ERROR: json file is not a valid Spine animation...
json data is malformed
I tried other projects made with 3.2 version and give me more errors like
"ERROR: json file is not a valid Spine animation...
atlas file references >1 images'
Seems like what is originally made with the latest Spine version has a problem, while
what was originally made with old versions works well. That is of course a rough assumption.
I attach the two project, how do I solve this?
Thanks in advance for your help.
GameMaker should be able to tell you what is the latest version of the Spine editor that they support. The Spine runtime version (in this case, the version of the Spine runtime that GameMaker uses) and the editor version need to be kept in sync.
"skinnedmesh" in the JSON was changed to "weightedmesh" starting with, I believe, Spine 3.0.00. This would indicate that GameMaker is using a version 2.1.27 compatible runtime. The reason the old spineboy works is because it doesn't use any features that have evolved or been added since 2.1.27 (no meshes, no shear timelines, etc).
You can change the version of Spine you are using from the Settings dialog:
http://esotericsoftware.com/spine-settings#Version
If you have projects that have been saved with a newer version of Spine, an older version of Spine won't be able to open them. To get around this you can export to JSON, then use Import Data
to bring the data into an older version of Spine. However, you may need to edit the JSON data to match the old version of Spine. Eg, renamed "weightedmesh" to "skinnedmesh" and delete any "shear" timeline entries. Alternatively, you can look in your Spine backups folder (found by clicking the Backups
button on the Settings dialog) for older versions of your project files.
That was very helpful Nate, thank you !
Hey Nate, I've run into the same problem as Speed, but I'm having trouble with your solution.
I received the same error message while importing a recent spine project to GameMaker Studio:
"Requested value 'weightedmesh' was not found.
ERROR: json file is not a valid Spine animation...
json data is malformed"
However, after reverting Spine to Version 2.1.27 and replacing "weightedmesh" in the JSON file (my project has no "shear" timeline entries), I still can't import the data into spine. Every time I try I receive a generic error message telling me to make sure I'm importing a valid JASON.
Sounds like you might have edited the JSON to be invalid. Did you look in your spine.log file?
It seems like Spine 2.1.27 is looking for a mix value that my json might be missing?
Here's the first line from the error in the Spine log when I try and import data:
"java.lang.IllegalArgumentException: Named value not found: mix"
Nate, is there any news on Spine 3.0 support in Gamemaker Studio?? It sucks that I can't use what I've been working on, hope we get support soon!
GameMaker manages their runtime integration. Currently we have most runtimes up to v3.1, so they are free to implement those. We are working on getting all the runtimes up to date. Soon!