【新手使用,出问题】动画播放,整个骨骼图片是散开的。

编辑器和cocos工程代码 都是前天刚下载的。
CocoStudio 版本号 1.0.2.0
cocos2dx 版本号 cocos2d-x-2.2.0

从动画编辑器中自带的 手雷小猫工程中,直接到处资源,放到cocos2dx的资源目录下。

先上图:

cocos工程里除了给helloCpp引用了 Extensions.lib等lib包外,代码还是HelloWorldScene的初始代码。

在HelloWorld::init() 按照 编辑器帮助中,添加了如下 代码

CCArmatureDataManager::sharedArmatureDataManager()->addArmatureFileInfo(“DemoPlayer0.png”,“DemoPlayer0.plist”,“DemoPlayer.ExportJson”);
CCArmatureDataManager::sharedArmatureDataManager()->addArmatureFileInfo(“DemoPlayer1.png”,“DemoPlayer1.plist”,“DemoPlayer.ExportJson”);
CCArmature *armature = CCArmature::create(“DemoPlayer”);
armature->getAnimation()->playByIndex(1);
armature->setScale(0.5f);
armature->setPosition(ccp(visibleSize.width * 0.5, visibleSize.height * 0.5));
this->addChild(armature,2);

都是很简单的demo代码。但是还是出问题了。
求教。

感觉这什么都没有干,很简单的一个操作,就出问题了,你们都好好的么。。。

楼主你好,你使用的应该是高分辨率的屏幕,cocos2d-x版本吧?如果是的话建议看这个帖子:
http://www.cocoachina.com/bbs/read.php?tid=161698

找到问题了
根据版主的链接指引,确实是分辨率问题。

从 CocoStudio直接下载的cocos2dx工程中。默认的
设计大小 被设置成了 DESIGN_RESOLUTION_480X320 (AppMacros.h中)
而屏幕大小被设置的远远大于这个值。

导致在 AppDelegate.cpp中检测屏幕适配时,
pDirector->setContentScaleFactor(XXX, XXX) 被设置成了 远大于 1。
于是 动画图元中某些信息,遭到缩放。