From 6352e8e3196f78388b6c771073f9e03eaa612673 Mon Sep 17 00:00:00 2001 From: Kae <80987908+Novaenia@users.noreply.github.com> Date: Tue, 20 Jun 2023 14:33:09 +1000 Subject: everything everywhere all at once --- source/frontend/StarInterfaceCursor.hpp | 35 +++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 source/frontend/StarInterfaceCursor.hpp (limited to 'source/frontend/StarInterfaceCursor.hpp') diff --git a/source/frontend/StarInterfaceCursor.hpp b/source/frontend/StarInterfaceCursor.hpp new file mode 100644 index 0000000..2f58867 --- /dev/null +++ b/source/frontend/StarInterfaceCursor.hpp @@ -0,0 +1,35 @@ +#ifndef STAR_INTERFACE_CURSOR_HPP +#define STAR_INTERFACE_CURSOR_HPP + +#include "StarJson.hpp" +#include "StarAnimation.hpp" + +namespace Star { + +class InterfaceCursor { +public: + InterfaceCursor(); + + // Sets the cursor to the default defined in interface.config + void resetCursor(); + + // Sets the cursor config to the given config IF the config is different than + // the current one. Expects a full asset path to the cursor config. + void setCursor(String const& configFile); + + Drawable drawable() const; + Vec2I size() const; + Vec2I offset() const; + + void update(float dt); + +private: + String m_configFile; + Vec2I m_offset; + Vec2I m_size; + MVariant m_drawable; +}; + +} + +#endif -- cgit v1.2.3