• RuntimesGodot
  • Godot 4.3 C# with Spine 4.2 doesn't run on export

Hi, I've got errors from log adb logcat -s godot when try to run exported project for android
The App doesn't load, only Godot Icon shows up.

USER ERROR: Can't load dependency: res://assets/spine/cat_spine_skeleton_data_resource.tres.
10-04 13:54:14.687 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:461)
10-04 13:54:14.687 25715 25762 E godot   : USER ERROR: Error when trying to parse Variant.
10-04 13:54:14.687 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:505)
10-04 13:54:14.687 25715 25762 E godot   : USER ERROR: Error when trying to parse Variant.
10-04 13:54:14.687 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:492)
10-04 13:54:14.687 25715 25762 E godot   : USER ERROR: Failed loading resource: res://.godot/exported/133200997/export-51652f9d5c9453037b2bf9159a453860-npc.scn. Make sure resources have been imported by opening the project in the editor at least once.
10-04 13:54:14.687 25715 25762 E godot   :    at: _load (core/io/resource_loader.cpp:284)
10-04 13:54:14.741 25715 25762 E godot   : USER ERROR: Can't load dependency: res://scenes/npc.tscn.
10-04 13:54:14.741 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:461)
10-04 13:54:14.741 25715 25762 E godot   : USER ERROR: Error when trying to parse Variant.
10-04 13:54:14.741 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:505)
10-04 13:54:14.741 25715 25762 E godot   : USER ERROR: Error when trying to parse Variant.
10-04 13:54:14.741 25715 25762 E godot   :    at: parse_variant (core/io/resource_format_binary.cpp:492)
10-04 13:54:14.742 25715 25762 E godot   : USER ERROR: Failed loading resource: res://.godot/exported/133200997/export-3ad5c15c4f3250da0cc7c1af1770d85f-main.scn. Make sure resources have been imported by opening the project in the editor at least once.        
10-04 13:54:14.742 25715 25762 E godot   :    at: _load (core/io/resource_loader.cpp:284)
10-04 13:54:14.742 25715 25762 E godot   : USER ERROR: Failed loading scene: res://scenes/main.tscn.
10-04 13:54:14.742 25715 25762 E godot   :    at: start (main/main.cpp:3897)
10-04 13:54:14.743 25715 25762 E godot   : USER ERROR: Condition "default_certs != nullptr" is true.
10-04 13:54:14.743 25715 25762 E godot   :    at: load_default_certificates (modules/mbedtls/crypto_mbedtls.cpp:361)
10-04 13:54:14.762 25715 25762 E godot   : USER ERROR: No loader found for resource: res://.godot/exported/133200997/export-8979be626377eb1fcf5ed7cd4f2f0072-cat_spine_skeleton_data_resource.res (expected type: SpineSkeletonDataResource)
10-04 13:54:14.762 25715 25762 E godot   :    at: _load (core/io/resource_loader.cpp:291)

In Editor everything plays without errors and Spine Character shows correctly.
I tried to delete .godot and re-import assets, checked for missing references but nothing helped.
Is there any solution to deal with it?

Related Discussions
...

The error messages you are encountering suggest that the exported project is unable to load certain resources, specifically the SpineSkeletonDataResource and other scene files. Here are some steps you can take to resolve this issue:

  1. Ensure Resources are Imported: Make sure that all resources, including the Spine assets, are properly imported in the Godot editor. Open the project in the Godot editor and verify that there are no import errors.

  2. Check Export Settings: Verify that the export settings include all necessary resources. Sometimes, resources might not be included in the export if they are not directly referenced in the scenes or scripts.

  3. Re-import Assets: As you mentioned, you have already tried re-importing assets. Ensure that after re-importing, you save the project and re-export it.

  4. Resource Paths: Double-check the paths of the resources in your project. Ensure that the paths are correct and that the files exist in the specified locations.

  5. Export Templates: Make sure you are using the correct export templates for your Godot version. If you have custom templates, ensure they are correctly set up.

  6. Check for Missing Dependencies: Ensure that all dependencies for the Spine runtime are included in the export. This includes any additional scripts or modules that might be required.

  7. Test on a Different Device: Sometimes, issues can be device-specific. Try running the exported project on a different Android device to see if the issue persists.

If these steps do not resolve the issue, you may need to investigate further by checking the Godot export logs for any additional clues.

Also I noticed when .godot folder is deleted and Editor re-imported the assets I've got such output in log

Godot Engine v4.3.stable.mono.custom_build (c) 2007-present Juan Linietsky, Ariel Manzur & Godot Contributors.
  Failed to create an autoload, script 'res://scripts/GameManager.cs' is not compiling.
  Unable to open file: res://.godot/imported/cat.png-65bd3f313402e9bf026bff52e079d919.ctex.
  Failed loading resource: res://.godot/imported/cat.png-65bd3f313402e9bf026bff52e079d919.ctex. Make sure resources have been imported by opening the project in the editor at least once.
  Failed loading resource: res://assets/spine/cat.png. Make sure resources have been imported by opening the project in the editor at least once.
  D:\a\spine-runtimes\spine-runtimes\spine-godot\spine_godot\SpineAtlasResource.cpp:74 - Can't load texture: "res://assets/spine/cat.png"

this is a weird path D:\a\spine-runtimes\spine-runtimes\spine-godot\spine_godot\SpineAtlasResource.cpp:74
perhaps it's a Virtual Drive withing Godot Editor?!

The path stems from the debug symbols the compiler emits. We compile our builds with GitHub actions, which places the source tree in D:\a\spine-runtimes.

The actual error is:

No loader found for resource: res://.godot/exported/133200997/export-8979be626377eb1fcf5ed7cd4f2f0072-cat_spine_skeleton_data_resource.res (expected type: SpineSkeletonDataResource)

Which means you are using an Android export template that does not have spine-godot support, which makes sense, as spine-godot + C# is currently limited to desktop operating systems and web. See:

EsotericSoftware/spine-runtimes2442

It is also indicated on the download page:

I'm currently working on turning spine-godot into a GDExtension, which should hopefully also enable C# support on Android and iOS.

  • coolerinc 님이 이 게시물을 좋아합니다..

@Mario Thanks for your explanation
be waiting for android support in the future