30 ~
Sprite()
override =
default;
49 Sprite(std::shared_ptr<Widget> parent, ImageId imageId) :
Sprite(parent) {
65 mCurrentVector = vector;
66 mVectorTicks = (float) time;
78 PositionInt mTextureFrame{};
79 PositionInt mTextureOffset{};
Sprite(std::shared_ptr< Widget > parent, ImageId imageId)
Constructor.
Definition: Sprite.h:49
void setImageId(ImageId imageId)
Set the ImageRepository::ImageId of the texture to use as the sprite.
Definition: Sprite.h:73
void setVector(Size< float > vector, uint32_t time)
Give the sprite a vector to travel and a time in milliseconds that it should take to travers...
Definition: Sprite.h:64
void draw(sdl::Renderer &renderer, RectangleInt parentRect) override
Draw the sprite.
Definition: Sprite.cpp:16
static constexpr ImageId InvalidImageId
An invalid image ID which may be used for initialization.
Definition: ImageRepository.h:48
A sprite is a free roaming texture that is directed using Signals and Slots.
Definition: Sprite.h:27
Written as a workaround for an issue in the SDL2 Library.
Definition: Renderer.h:64
ToDo: There is an issue that the initial scroll interaction is lost if the click/press lands on a Wid...
Definition: CelestialOverlay.cpp:13