diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2025-01-08 15:03:14 +0100 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2025-01-08 15:03:14 +0100 |
commit | 261a2cfd2bedafbc7fcf54e1b86adee206dea519 (patch) | |
tree | f099bca292e99ae54035f9a5ac7a455eec073c3e /game/hud/HudScript.h | |
parent | d9c67da9b8c2d8d25ef4dd2c700ddc78573d3a60 (diff) | |
parent | 0b9574bdd6c5968c07bcf165d66032b75649b5da (diff) |
merge w/ master
Diffstat (limited to 'game/hud/HudScript.h')
-rw-r--r-- | game/hud/HudScript.h | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/game/hud/HudScript.h b/game/hud/HudScript.h index 8e7e8fc..2b789db 100644 --- a/game/hud/HudScript.h +++ b/game/hud/HudScript.h @@ -1,13 +1,25 @@ #pragma once -#include "api/Script.h" -#include "manager/SaveManager.h" +#include <crepe/api/Event.h> +#include <crepe/api/Script.h> +#include <crepe/manager/SaveManager.h> + +struct GetCoinEvent : public crepe::Event { + int amount_of_coins; +}; class HudScript : public crepe::Script { public: void init() override; void frame_update(crepe::duration_t dt) override; + bool get_coin(const GetCoinEvent e); + bool toggle_fps(crepe::KeyPressEvent ev); + bool save(); + private: - crepe::SaveManager* savemgr; + crepe::SaveManager * savemgr; bool show_fps = false; + int coin_amount = 0; + std::string coin_amount_st = ""; + std::string distance_st = ""; }; |