• Editor
  • Please Check this video. (spine on cocos2d-x)

Related Discussions
...

No idea what the bug could be. Maybe your resources are messed up somehow? It's the same Spine code that runs in both places.

I find a reason.

CCDirector *pDirector = CCDirector::sharedDirector();
pDirector->setOpenGLView(CCEGLView::sharedOpenGLView());


CCSize screenSize = CCEGLView::sharedOpenGLView()->getFrameSize();
CCSize designSize = CCSizeMake(480, 320);

std::vector<std::string> searchPaths;


if (screenSize.height > 320)
{
    searchPaths.push_back("hd");
    searchPaths.push_back("sd");
    
    pDirector->setContentScaleFactor(640.0f/designSize.height);
}
else
{
    searchPaths.push_back("sd");
    pDirector->setContentScaleFactor(320.0f/designSize.height);
}

  
CCFileUtils::sharedFileUtils()->setSearchPaths(searchPaths);
 


CCEGLView::sharedOpenGLView()->setDesignResolutionSize(designSize.width, designSize.height, kResolutionShowAll);

After setContentScaleFactor function call.. It make a this bug.
🙂

His problem is he's messing around with different resolution source assets... don't think spine is the problem.

I've seen that problem when loading the wrong sprite sheet and atlas combo. All the coordinates are wrong, thus the problem.