//In GameScene.cpp
this->schedule(schedule_selector(GameScene::Update));
void GameScene::Update(float dt){
}
//In GameScene.h
class GameScene : public cocos2d::Layer
{
public:
static cocos2d::Scene* createScene();
virtual bool init();
CREATE_FUNC(GameScene);
private:
void Update(float dt);
};
//In GameScene.cpp
this->scheduleUpdate();
void GameScene::update(float dt){
}
//In GameScene.h
class GameScene : public cocos2d::Layer
{
public:
static cocos2d::Scene* createScene();
virtual bool init();
CREATE_FUNC(GameScene);
private:
void update(float dt);
};
No comments:
Post a Comment