Hi, in my game I am creating an animation class,
The class will take in a spritesheet and on request return an image from that sheet.
However I am unsure as to how I can get part of the main image.
I did think of having a sprite which has the main image and then setting its subrect to what I want and then getting the sprites image, but from what I read this would just return the original image so I am not sure as to how I could do this.
I am also unsure of how I can get a sprites position after moving it.
If I use sprite::move then IIRC it moves the sprite to an offset from its original position, but when using getPosition this just returns its original position, so is there a way to get its current position?
Or would i just have to not use move and do something like:
sprite.setPosition(sprite.getPos().x +5, sprite.getPos().y -3);