Light-weight timer. More...
#include <CCScheduler.h>
Public Member Functions | |
float | getInterval () const |
get interval in seconds More... | |
var | getInterval () |
get interval in seconds More... | |
local | getInterval () |
get interval in seconds More... | |
void | setInterval (float interval) |
set interval in seconds More... | |
var | setInterval ( var interval) |
set interval in seconds More... | |
local | setInterval ( local interval) |
set interval in seconds More... | |
void | setupTimerWithInterval (float seconds, unsigned int repeat, float delay) |
var | setupTimerWithInterval ( var seconds, var repeat, var delay) |
local | setupTimerWithInterval ( local seconds, local repeat, local delay) |
virtual void | trigger ()=0 |
var | trigger () |
local | trigger () |
virtual void | cancel ()=0 |
local | cancel () |
void | update (float dt) |
triggers the timer More... | |
var | update ( var dt) |
triggers the timer More... | |
local | update ( local dt) |
triggers the timer More... | |
Public Member Functions inherited from Ref | |
void | retain () |
Retains the ownership. More... | |
void | release () |
Release the ownership immediately. More... | |
local | release () |
Release the ownership immediately. More... | |
Ref * | autorelease () |
Release the ownership sometime soon automatically. More... | |
unsigned int | getReferenceCount () const |
Returns the Ref's current reference count. More... | |
virtual | ~Ref () |
Protected Member Functions | |
Timer () | |
Timer () | |
Timer () | |
Protected Member Functions inherited from Ref | |
Ref () | |
Constructor. More... | |
Ref () | |
Constructor. More... | |
Protected Attributes | |
Scheduler * | _scheduler |
local | _scheduler |
float | _elapsed |
var | _elapsed |
local | _elapsed |
bool | _runForever |
var | _runForever |
local | _runForever |
bool | _useDelay |
var | _useDelay |
local | _useDelay |
unsigned int | _timesExecuted |
var | _timesExecuted |
local | _timesExecuted |
unsigned int | _repeat |
var | _repeat |
local | _repeat |
float | _delay |
var | _delay |
local | _delay |
float | _interval |
var | _interval |
local | _interval |
Protected Attributes inherited from Ref | |
unsigned int | _referenceCount |
count of references More... | |
Light-weight timer.
|
protected |
|
protected |
|
protected |
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
|
inline |
get interval in seconds
|
inline |
get interval in seconds
|
inline |
get interval in seconds
|
inline |
set interval in seconds
|
inline |
set interval in seconds
|
inline |
set interval in seconds
void setupTimerWithInterval | ( | float | seconds, |
unsigned int | repeat, | ||
float | delay | ||
) |
var setupTimerWithInterval | ( | var | seconds, |
var | repeat, | ||
var | delay | ||
) |
local setupTimerWithInterval | ( | local | seconds, |
local | repeat, | ||
local | delay | ||
) |
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
|
pure virtual |
Implemented in TimerTargetCallback, and TimerTargetSelector.
void update | ( | float | dt) |
triggers the timer
var update | ( | var | dt) |
triggers the timer
local update | ( | local | dt) |
triggers the timer
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |