[已解决]求助关于使用armature来实现人物变身功能

是这样小弟打算实现一个变身功能
void Runner::changeModel(const char* modelname)
{
CCArmatureDataManager::sharedArmatureDataManager()->addArmatureFileInfo(“fish-040.png”,“fish-040.plist”,“fish-04.ExportJson”);
if(this->mLayer)
{
if(armatureBody){
armatureBody->removeFromParent();
this->mLayer->removeChild(armatureBody);
//armatureBody->release();
//armatureBody = NULL;
}

    armatureBody = cocos2d::extension::CCArmature::create("fish-04");
    initBody();
    initShape("running");
    armatureBody->getAnimation()->playByIndex(0);
    armatureBody->setPosition(100,100);
    mLayer->addChild(armatureBody);
}

}
可是总有问题 就是我的armature更换失败了 造成了armatruedate的数据野指针 应该是我使用方法不对造成的 求指导

建议删除原有的armature,并创建新的armature。

— Begin quote from ____

引用第1楼hanrea于2014-05-16 09:51发表的 回 楼主(yuwenbai) 的帖子 :
建议删除原有的armature,并创建新的armature。 http://www.cocoachina.com/bbs/job.php?action=topost&tid=201936&pid=953151

— End quote

我就是这么做的啊 难道我做的不对吗 希望版主看了我的代码之后能够指点一二 莫不是张成?