CCCallFuncND::create error C2355: “this”: 只能在非静态成员函数的内部引用

void MovePk(Player* play,Poker* pk)
{
CCMoveTo* move;
CCCallFuncND* func;
float time = 0.05;
play->getArrPk()->addObject(pk);
move = CCMoveTo::create(time,play->getPoint());
func = CCCallFuncND::create(this,callfuncND_selector(GameScene::func),play);
CCSequence* sequence = CCSequence::create(move,func,NULL);
pk->runAction(sequence);

}

error C2355: “this”: 只能在非静态成员函数的内部引用

error C2248: “GameScene::func”: 无法访问 private 成员(在“GameScene”类中声明)

加void GameScene::MovePk(Player* play,Poker* pk)

你可能感兴趣的:(visual2013,cocos2dx3.8)