Calls a 'callback'.
More...
#include <ActionInstant.h>
Inherits ActionInstant.
Inherited by CallFuncN.
|
|
virtual void | execute () |
| | Executes the callback.
|
| void | update (float time) override |
|
bool | initWithFunction (const std::function< void()> &func) |
| | initializes the action with the std::function<void()> @lua NA
|
| void | step (float dt) override |
| void | update (float time) override |
|
| static CallFunc * | create (const std::function< void()> &func) |
| | Creates the action with the callback of type std::function<void()>.
|
◆ create()
| CallFunc * create |
( |
const std::function< void()> & | func | ) |
|
|
static |
Creates the action with the callback of type std::function<void()>.
This is the preferred way to create the callback. When this function bound in js or lua ,the input param will be changed. In js: var create(var func, var this, var [data]) or var create(var func). In lua:local create(local funcID).
- Parameters
-
| func | A callback function need to be executed. |
- Returns
- An autoreleased CallFunc object.
◆ update()
| void update |
( |
float | time | ) |
|
|
override |
The documentation for this class was generated from the following file: