Hi, i am using spine-cocos2d-objc in my project. My assets are located at server, so i have to download it first. I placed my asset in sandbox folder like file:///Users/nihua/Library/Developer/CoreSimulator/Devices/A8CCF944-2559-4853-A6AC-FC009BE33D86/data/Containers/Data/Application/D78A7701-27A0-4568-ACEA-D46A00A0FE16/Documents/characterAsset.json

After the download is complete, and the asset already in there, I fail to load it with
skeletonNode = [SkeletonAnimation skeletonWithFile:"characterAsset.json" atlasFile:"characterAsset.json" scale:0.7];
But, I get this error instead
2019-08-07 10:26:03.810378+0700 OwlPlast[64861:2753161] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Error reading atlas file: characterAsset.json'

So my question is, could spine load skeleton and atlas file with the URL in my sandbox app? Thank you.
  • Posts: 10


Spine uses cocos2d's file loading APIs:

spine-runtimes/spine-cocos2d-objc.m at 3.8

I would assume the file:/// prefix might be the culprit.
User avatar

  • Posts: 1936

Return to Runtimes