Build error related to Spine models

#1

Hi there,

I cannot build anymore my game (for android). Last time I tried was December the 7-th of 2019 and it worked fine. The build process starts and after a while the following message appears in a window

An error occurred
java.lang.NullPointerException: Unknown

Nothing more! Is there a report in some file? How can I try to solve this?

Here are the information about editor / engine:

Of course the game runs fine launched from the editor.

Thanks!

1 Like

#2

The editor generates a log.txt:

Editor logs are located here:

  • Windows: C:\Users\ **Your Username** \AppData\Local\Defold
  • macOS: /Users/ **Your Username** /Library/Application Support/ or ~/Library/Application Support/Defold
  • Linux: ~/.Defold

If you use native extensions there’s also a build.txt in the build folder.

0 Likes

#3

I think this is the relevant log about the build error in the file editor2.2020-02-25.log:

2020-02-25 16:42:14.921 16893639 [JavaFX Application Thread] ERROR editor.error-reporting - {:line 98}
java.lang.NullPointerException: null
at com.dynamo.bob.util.SpineSceneUtil.loadSkin(SpineSceneUtil.java:736)
at com.dynamo.bob.util.SpineSceneUtil.loadJson(SpineSceneUtil.java:893)
at com.dynamo.bob.pipeline.SpineSceneBuilder.build(SpineSceneBuilder.java:384)
at com.dynamo.bob.Project.runTasks(Project.java:989)
at com.dynamo.bob.Project.doBuild(Project.java:790)
at com.dynamo.bob.Project.build(Project.java:441)
at editor.pipeline.bob$run_commands_BANG_$fn__37203.invoke(bob.clj:86)
at editor.pipeline.bob$run_commands_BANG_.invokeStatic(bob.clj:85)
at editor.pipeline.bob$bob_build_BANG_.invokeStatic(bob.clj:127)
at editor.disk$async_bob_build_BANG_$fn__38225$fn__38228$fn__38229.invoke(disk.clj:205)
at clojure.core$binding_conveyor_fn$fn__5739.invoke(core.clj:2030)
at clojure.lang.AFn.call(AFn.java:18)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

Is this the file? If so, it seems something related to spine. I have a (unique) spine model in the game and it runs perfectly fine.

Any help?

0 Likes

#4

What if you take this spine model and move it to an empty project?

0 Likes

#5

doing

0 Likes

#6

Empty project with only the main.collection with a unique game object with the spine model as unique component. Same error; here is the log:

2020-02-25 19:48:33.602 247470 [JavaFX Application Thread] ERROR editor.error-reporting - {:line 98}
java.lang.NullPointerException: null
at com.dynamo.bob.util.SpineSceneUtil.loadSkin(SpineSceneUtil.java:736)
at com.dynamo.bob.util.SpineSceneUtil.loadJson(SpineSceneUtil.java:893)
at com.dynamo.bob.pipeline.SpineSceneBuilder.build(SpineSceneBuilder.java:384)
at com.dynamo.bob.Project.runTasks(Project.java:989)
at com.dynamo.bob.Project.doBuild(Project.java:790)
at com.dynamo.bob.Project.build(Project.java:441)
at editor.pipeline.bob$run_commands_BANG_$fn__37203.invoke(bob.clj:86)
at editor.pipeline.bob$run_commands_BANG_.invokeStatic(bob.clj:85)
at editor.pipeline.bob$bob_build_BANG_.invokeStatic(bob.clj:127)
at editor.disk$async_bob_build_BANG_$fn__38225$fn__38228$fn__38229.invoke(disk.clj:205)
at clojure.core$binding_conveyor_fn$fn__5739.invoke(core.clj:2030)
at clojure.lang.AFn.call(AFn.java:18)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

(And it runs fine)

0 Likes

#7

Can you please share the project so that we can take a look?

0 Likes

#8

I sent you a message with the zipped project. But I am not sure if I have done it right… sorry. Could you please confirm you have received it?

0 Likes

#9

Any news? Have same problem.

java.lang.NullPointerException: null
	at com.dynamo.bob.util.SpineSceneUtil.loadSkin(SpineSceneUtil.java:736)
	at com.dynamo.bob.util.SpineSceneUtil.loadJson(SpineSceneUtil.java:893)
	at com.dynamo.bob.pipeline.SpineSceneBuilder.build(SpineSceneBuilder.java:384)
	at com.dynamo.bob.Project.runTasks(Project.java:1007)
	at com.dynamo.bob.Project.doBuild(Project.java:808)
	at com.dynamo.bob.Project.build(Project.java:443)
	at editor.pipeline.bob$run_commands_BANG_$fn__37203.invoke(bob.clj:86)
	at editor.pipeline.bob$run_commands_BANG_.invokeStatic(bob.clj:85)
	at editor.pipeline.bob$bob_build_BANG_.invokeStatic(bob.clj:127)
	at editor.disk$async_bob_build_BANG_$fn__38225$fn__38228$fn__38229.invoke(disk.clj:205)
	at clojure.core$binding_conveyor_fn$fn__5739.invoke(core.clj:2030)
	at clojure.lang.AFn.call(AFn.java:18)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:834)
0 Likes

#10

Hi,

if I understand correctly Defold supports only Spine 2.X. However I was able to use Spine 3.8.84 (my latest version) by removing any sprite swaps during animation.

Ciao

1 Like

#11

Thanks… What is sprite swap, where find it,?) I do not know spine, I only add animations))

0 Likes

#12

During an animation Spine allows you to change the image of an attachment slot. I think this should the right terminology Spine uses, sorry for being sloppy in my previous answer. In my case, it seems that the build process does not like the changing of the images. At least for project exported with Spine 3.8.84.

Hope this may help, I am not an expert of Spine nor of Defold…

1 Like

#13

You need to make sure your animators know of the limitations. I think you can configure Spine to use and generate Spine 2.x compatible files.

1 Like

#14

Yes, i make a list with that limitations. And when something broken i add more info to that list=)

But in that case.Looks like there are no new features of spine in animation. Also It worked ok in editor, but bundle not worked.

I am sure that there are no changing image of an attachment slot.Animations not need it.Mb it was added somewhere by mistake.I will check it tomorrow.

Also it can be problem with cyrillic. All images use cyrillic names=)

No i can’t. I can say animator to use 2.x spine version instead of current. (new version contains a lot of bugfixes and improvments for editor,so it is better to use last version with list of limitations.)

1 Like

#15

The issue with @roccosaienz spine scene was that some animations used slots that weren’t predefined.
This isn’t a feature we’ve supported before, but it seems that our editor happens to allow, probably since the last hot fix to at least allow loading Spine 3.8.x scenes.

Although it’s possible to spend time tracking down that specific discrepancy and maybe find a fix for it, we will instead put our focus in making the Spine support into an extension, allowing us to work on other more urgent things in the future. This work has not yet started, and we have no ETA for this.

2 Likes

#16

Thanks. Not sure what help.
I remove all skins(animation not need it, i add it only because think that bob need skin=)), rename all cyrillic to english, and remove multiple images from one bone.

Looks like problem was with multiple images, and with skin.
Try spine with cyrrilic and it worked. So problem was with multiple images

Move spine to extension is cool.

But the best way to release mesh support(you show it somewhere in forum, any eta?). When we have meshes added official spine runtime, should not be a problem=)

1 Like

#17

The mesh support is part of that solution yes.
We’re hoping for the next beta, but might be pushed to the next one after that.

2 Likes

#18

I encountered this error today too. Spine scene was using sprite swapping and I assumed it was allowed… I thought it used to be? It works in engine while building, but not when bundling.

Getting a Spine extension with all official features would be amazing. There are other features like masks that would be incredibly useful if they could be fully supported at least within GUI.

0 Likes

#19

We’ll look at the error messages in that issue and try to figure out what is wrong. Can you please also provide in the issue a minimal repro case?

2 Likes

#20

Done!

2 Likes