Axmol Engine 2.4.0-258ceca
|
Calls a 'callback' with the node as the first argument. More...
#include <ActionInstant.h>
Inherits CallFunc.
Public Member Functions | |
virtual void | execute () override |
Executes the callback. | |
bool | initWithFunction (const std::function< void(Node *)> &func) |
initializes the action with the std::function<void(Node*)> | |
![]() | |
virtual void | update (float time) override |
bool | initWithFunction (const std::function< void()> &func) |
initializes the action with the std::function<void()> @lua NA | |
![]() | |
virtual void | step (float dt) override |
Static Public Member Functions | |
static CallFuncN * | create (const std::function< void(Node *)> &func) |
Creates the action with the callback of type std::function<void()>. | |
![]() | |
static CallFunc * | create (const std::function< void()> &func) |
Creates the action with the callback of type std::function<void()>. | |
Calls a 'callback' with the node as the first argument.
N means Node. @js NA
Creates the action with the callback of type std::function<void()>.
This is the preferred way to create the callback.
func | A callback function need to be executed. |