Moves a Node object to the position x,y.
More...
#include <ActionInterval.h>
Inherits MoveBy.
|
| bool | initWithDuration (float duration, const Vec2 &position) |
| | initializes the action
|
| bool | initWithDuration (float duration, const Vec3 &position) |
| | initializes the action
|
| void | update (float time) override |
|
bool | initWithDuration (float duration, const Vec2 &deltaPosition) |
| | initializes the action
|
| float | getElapsed () |
| | How many seconds had elapsed since the actions started to run.
|
| void | setAmplitudeRate (float amp) |
| | Sets the amplitude rate, extension in GridAction.
|
| float | getAmplitudeRate () |
| | Gets the amplitude rate, extension in GridAction.
|
| void | step (float dt) override |
|
bool | initWithDuration (float d) |
| | initializes the action
|
|
| static MoveTo * | create (float duration, const Vec2 &position) |
| | Creates the action.
|
| static MoveTo * | create (float duration, const Vec3 &position) |
| | Creates the action.
|
| static MoveBy * | create (float duration, const Vec2 &deltaPosition) |
| | Creates the action.
|
| static MoveBy * | create (float duration, const Vec3 &deltaPosition) |
| | Creates the action.
|
Moves a Node object to the position x,y.
x and y are absolute coordinates by modifying it's position attribute. Several MoveTo actions can be concurrently called, and the resulting movement will be the sum of individual movements.
- Since
- v2.1beta2-custom
◆ create() [1/2]
| MoveTo * create |
( |
float | duration, |
|
|
const Vec2 & | position ) |
|
static |
Creates the action.
- Parameters
-
| duration | Duration time, in seconds. |
| position | The destination position in 2d. |
- Returns
- An autoreleased MoveTo object.
◆ create() [2/2]
| MoveTo * create |
( |
float | duration, |
|
|
const Vec3 & | position ) |
|
static |
Creates the action.
- Parameters
-
| duration | Duration time, in seconds. |
| position | The destination position in 3d. |
- Returns
- An autoreleased MoveTo object.
◆ initWithDuration() [1/2]
| bool initWithDuration |
( |
float | duration, |
|
|
const Vec2 & | position ) |
initializes the action
- Parameters
-
◆ initWithDuration() [2/2]
| bool initWithDuration |
( |
float | duration, |
|
|
const Vec3 & | position ) |
initializes the action
- Parameters
-
The documentation for this class was generated from the following file: