|
|
| Enemy (std::shared_ptr< SDL_Texture > texture, SDL_Renderer *renderer) |
| | Create Enemy.
|
| |
| void | moveTo (const int x, const int y) |
| | Move enemy to specified position.
|
| |
| void | moveToCell (std::pair< int, int > pathToCell) |
| | Move enemy for specified diff of cells.
|
| |
| bool | isMovingToCell () const |
| | Return is enemy moving to cell or not.
|
| |
| bool | canAttack () const |
| | Can enemy attack.
|
| |
| int | getAttackRadius () const |
| | Get the Attack Radius of enemy.
|
| |
| void | setAIType (AIType type) |
| | Set AI type.
|
| |
| virtual void | update (const unsigned int delta) override |
| | Update movement of enemy.
|
| |
|
void | generateNewPath () |
| | Generate new path if enemy finish movement.
|
| |
|
void | revertLastMove () |
| | Revert last movement of creature.
|
| |
| void | setMoving (bool isMoving) |
| | Set creature to move.
|
| |
| bool | isMoving () const |
| | Is creature moving at this moment.
|
| |
|
| Sprite (std::shared_ptr< SDL_Texture > texture, SDL_Renderer *renderer) |
| | Create creature.
|
| |
| | Sprite (std::shared_ptr< SDL_Texture > texture, SDL_Renderer *renderer) |
| | Construct a new Sprite object.
|
| |
| void | addAnimation (std::shared_ptr< Animation > animation) |
| | Add animation to sprite.
|
| |
| | Object (SDL_Renderer *renderer) |
| | Construct a new object.
|
| |
|
virtual | ~Object () |
| | Destroy the object.
|
| |
| void | setSize (const int width, const int height) |
| | Set the Size of object.
|
| |
| void | setPosition (const int x, const int y) |
| | Set the Position of object (integer)
|
| |
| void | setPositionF (const float x, const float y) |
| | Set the Position of object (float/sub-pixel)
|
| |
| void | setClip (const int width, const int height, const int x, const int y) |
| | Set the Clip of source texture.
|
| |
| void | attachToCamera (bool isAttached=true) |
| | Attach object to camera movement.
|
| |
|
void | setVisible (bool isVisible) |
| | Toggle whether this object should currently be drawn.
|
| |
|
bool | isVisible () const |
| | Returns whether this object is currently drawable.
|
| |
| int | getWidth () const |
| | Get the Width of object.
|
| |
| int | getHeight () const |
| | Get the Height of object.
|
| |
| int | getPositionX () const |
| | Get the Position X of object (integer)
|
| |
| int | getPositionY () const |
| | Get the Position Y of object (integer)
|
| |
| float | getPositionXF () const |
| | Get the Position X of object (float)
|
| |
| float | getPositionYF () const |
| | Get the Position Y of object (float)
|
| |
| const SDL_Rect & | getRect () const |
| | Get Rect of object.
|
| |
| SDL_FRect | getRectF () const |
| | Get Rect of object (float position)
|
| |
| void | setFlip (SDL_RendererFlip flip) |
| | Set the Flip object.
|
| |
|
void | setColorMod (Uint8 r, Uint8 g, Uint8 b) |
| | Set texture color modulation applied during draw.
|
| |
| void | draw (const SDL_Rect &camera) const |
| | Draw object on the screen.
|
| |