R-Type
|
Class representing a sprite wrapper for sf::Sprite with additional functionality. More...
#include <SfmlTypes.hpp>
Public Member Functions | |
Sprite () | |
Default constructor for Sprite. More... | |
~Sprite ()=default | |
Destructor for Sprite. More... | |
const sf::Sprite & | getSprite () const override |
Returns the wrapped sf::Sprite. More... | |
void | load (const ITexture< sf::Texture, sf::Rect > &texture, bool resetRect=false) override |
Loads the sprite with a specified texture and optional reset of the texture rectangle. More... | |
void | setPosition (const Vector2< float > position) override |
Sets the position of the sprite. More... | |
void | setTextureRect (const IRect< int, sf::Rect > &newRect) override |
Sets the texture rectangle of the sprite. More... | |
void | setRect (const Recti &rect) |
Sets the texture rectangle of the sprite using a custom rectangle. More... | |
void | setScale (const float &x, const float &y) |
![]() | |
~ISprite ()=default | |
Destructor. More... | |
Class representing a sprite wrapper for sf::Sprite with additional functionality.
|
inline |
Default constructor for Sprite.
|
default |
Destructor for Sprite.
|
inlineoverridevirtual |
Returns the wrapped sf::Sprite.
Implements GameEngine::ISprite< sf::Sprite, sf::Texture, sf::Rect >.
|
inlineoverridevirtual |
Loads the sprite with a specified texture and optional reset of the texture rectangle.
texture | The texture to apply to the sprite |
resetRect | Flag indicating whether to reset the texture rectangle |
Implements GameEngine::ISprite< sf::Sprite, sf::Texture, sf::Rect >.
|
inlineoverridevirtual |
Sets the position of the sprite.
position | The new position of the sprite |
Implements GameEngine::ISprite< sf::Sprite, sf::Texture, sf::Rect >.
|
inline |
Sets the texture rectangle of the sprite using a custom rectangle.
rect | The custom rectangle defining the new texture rectangle |
|
inline |
|
inlineoverridevirtual |
Sets the texture rectangle of the sprite.
newRect | The new texture rectangle to set |
Implements GameEngine::ISprite< sf::Sprite, sf::Texture, sf::Rect >.