2011-06-14 14:31:25 +08:00
|
|
|
|
|
|
|
class CCTimer : public CCObject
|
|
|
|
{
|
2011-11-09 23:23:47 +08:00
|
|
|
ccTime getInterval(void);
|
|
|
|
void setInterval(ccTime fInterval);
|
|
|
|
void update(ccTime dt);
|
2011-06-14 14:31:25 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
class CCScheduler : public CCObject
|
|
|
|
{
|
2011-11-09 23:23:47 +08:00
|
|
|
ccTime getTimeScale(void);
|
|
|
|
void setTimeScale(ccTime fTimeScale);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2011-11-09 23:23:47 +08:00
|
|
|
void scheduleScriptFunc(const char *pszFuncName, ccTime fInterval, bool bPaused);
|
|
|
|
void unscheduleScriptFunc(const char *pszFuncName);
|
|
|
|
void scheduleUpdateForTarget(SelectorProtocol *pTarget, int nPriority, bool bPaused);
|
|
|
|
void unscheduleUpdateForTarget(const SelectorProtocol *pTarget);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2011-11-09 23:23:47 +08:00
|
|
|
void unscheduleAllSelectorsForTarget(SelectorProtocol *pTarget);
|
|
|
|
void unscheduleAllSelectors(void);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2011-11-09 23:23:47 +08:00
|
|
|
void pauseTarget(SelectorProtocol *pTarget);
|
|
|
|
void resumeTarget(SelectorProtocol *pTarget);
|
|
|
|
bool isTargetPaused(SelectorProtocol *pTarget);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2011-11-09 23:23:47 +08:00
|
|
|
static CCScheduler* sharedScheduler(void);
|
2011-06-14 14:31:25 +08:00
|
|
|
};
|
|
|
|
|
2011-11-09 23:23:47 +08:00
|
|
|
// } // namespace cocos2d
|