Commit 79a90ebc authored by louiz’'s avatar louiz’

Sprites can be update()d

parent 249d6ae3
......@@ -5,6 +5,7 @@
#include <world/position.hpp>
#include <gui/sprites/energy_bar.hpp>
#include <utils/time.hpp>
#include <assets/assets_manager.hpp>
class WorldSprite
......@@ -13,7 +14,9 @@ public:
WorldSprite() {}
virtual ~WorldSprite() {}
virtual void draw(sf::RenderTarget& surface, const sf::RenderStates& states) const = 0;
virtual void tick() = 0;
// TODO remove this tick()
virtual void tick() {};
virtual void update(const utils::Duration& dt) {}
virtual Position get_world_pos() const = 0;
static const EnergyBar standard_health_bar;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment