Axmol Engine 2.4.0-258ceca
Loading...
Searching...
No Matches
TiledGrid3DAction Class Reference

Base class for TiledGrid3D actions. More...

#include <ActionGrid.h>

Inherits GridAction.

Inherited by FadeOutTRTiles, JumpTiles3D, ShakyTiles3D, ShatteredTiles3D, ShuffleTiles, SplitCols, SplitRows, TurnOffTiles, and WavesTiles3D.

Public Member Functions

Quad3 getTile (const Vec2 &position) const
 Get the tile that belongs to a certain position of the grid.
 
Quad3 getOriginalTile (const Vec2 &position) const
 Get the non-transformed tile that belongs to a certain position of the grid.
 
void setTile (const Vec2 &position, const Quad3 &coords)
 Set a new tile to a certain position of the grid.
 
virtual GridBasegetGrid () override
 returns the grid
 
- Public Member Functions inherited from GridAction
bool initWithDuration (float duration, const Vec2 &gridSize)
 Initializes the action with size and duration.
 
- Public Member Functions inherited from ActionInterval
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.
 
virtual void step (float dt) override
 
bool initWithDuration (float d)
 initializes the action
 

Static Public Member Functions

static TiledGrid3DActioncreate (float duration, const Vec2 &gridSize)
 Create the action with size and duration.
 

Detailed Description

Base class for TiledGrid3D actions.

Member Function Documentation

◆ create()

static TiledGrid3DAction * create ( float duration,
const Vec2 & gridSize )
static

Create the action with size and duration.

Parameters
durationThe duration of the action. It's a value in seconds.
gridSizeSpecify the grid size of the action.
Returns
A pointer of TiledGrid3DAction. If creation failed, return nil. @lua NA

◆ getTile()

Quad3 getTile ( const Vec2 & position) const

Get the tile that belongs to a certain position of the grid.

Parameters
positionThe position of the tile want to get.
Returns
A quadrilateral of the tile. @js tile @lua NA

◆ getOriginalTile()

Quad3 getOriginalTile ( const Vec2 & position) const

Get the non-transformed tile that belongs to a certain position of the grid.

Parameters
positionThe position of the tile want to get.
Returns
A quadrilateral of the tile. @js originalTile @lua NA

◆ setTile()

void setTile ( const Vec2 & position,
const Quad3 & coords )

Set a new tile to a certain position of the grid.

Parameters
positionThe position of the tile.
coordsThe quadrilateral of the new tile. @lua NA

The documentation for this class was generated from the following file: