Animations can work on Sprites,Transformables, and Views and the arena shows the hit/miss text so it follows the entity and hides when the animation stops.

This commit is contained in:
Zed A. Shaw 2025-12-24 14:18:41 -05:00
parent 0d23cf9537
commit f175a5d4aa
3 changed files with 53 additions and 32 deletions

View file

@ -166,7 +166,11 @@ namespace components {
bool apply(sf::Sprite& target, sf::Vector2f pos);
bool apply(sf::View& view_out, sf::Vector2f pos, sf::Vector2f size);
bool apply(sf::Transformable& target, sf::Vector2f pos);
void lerp(sf::Vector2f& scale_out, sf::Vector2f& pos_out);
void tween(sf::Vector2f& scale_out, sf::Vector2f& pos_out);
bool next_frame();
void play();
float twitching();