diff options
author | Max-001 <maxsmits21@kpnmail.nl> | 2025-01-08 09:03:30 +0100 |
---|---|---|
committer | Max-001 <maxsmits21@kpnmail.nl> | 2025-01-08 09:03:30 +0100 |
commit | 93aa94921e027e05d7cb9908305af225c64b1ff2 (patch) | |
tree | 8beacc3b049a7150aa2cb5af501b158d11158a9e /game/menus/ButtonSubScene.h | |
parent | 1a61140ab5be8ede0aa19644cd29fb6770261f91 (diff) |
Make format
Diffstat (limited to 'game/menus/ButtonSubScene.h')
-rw-r--r-- | game/menus/ButtonSubScene.h | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/game/menus/ButtonSubScene.h b/game/menus/ButtonSubScene.h index 09c2fcd..c1c6de8 100644 --- a/game/menus/ButtonSubScene.h +++ b/game/menus/ButtonSubScene.h @@ -31,13 +31,13 @@ public: LARGE, }; //data struct - struct Data{ + struct Data { const std::string & text = "NODATA"; - const crepe::vec2 & text_offset = {0,0}; + const crepe::vec2 & text_offset = {0, 0}; const float text_width = 200; - const crepe::vec2 & icon_offset = {0,0}; + const crepe::vec2 & icon_offset = {0, 0}; const IconSelect icon_type = IconSelect::NONE; - const crepe::vec2 & position = {0,0}; + const crepe::vec2 & position = {0, 0}; const ScriptSelect script_type = ScriptSelect::NONE; const ButtonSelect button_type = ButtonSelect::LARGE; const float scale = 1; @@ -46,17 +46,22 @@ public: const std::string & tag = ""; const int sorting_layer_offset = 0; }; + public: - void create(crepe::Scene & scn,const Data & data); + void create(crepe::Scene & scn, const Data & data); + private: - void large_btn_overlay(crepe::GameObject & button_object,const Data & data); - void back_btn_overlay(crepe::GameObject & button_object,const Data & data); - void next_btn_overlay(crepe::GameObject & button_object,const Data & data); - void btn_color_side(crepe::GameObject & button_object,const crepe::vec2 & offset,const Data & data); - void btn_text(crepe::GameObject & button_object,const Data & data); - void set_script(crepe::GameObject & button_object,const Data & data); - void set_icon(crepe::GameObject & button_object,const Data & data); - void set_button_overlay(crepe::GameObject & button_object,const Data & data); + void large_btn_overlay(crepe::GameObject & button_object, const Data & data); + void back_btn_overlay(crepe::GameObject & button_object, const Data & data); + void next_btn_overlay(crepe::GameObject & button_object, const Data & data); + void btn_color_side( + crepe::GameObject & button_object, const crepe::vec2 & offset, const Data & data + ); + void btn_text(crepe::GameObject & button_object, const Data & data); + void set_script(crepe::GameObject & button_object, const Data & data); + void set_icon(crepe::GameObject & button_object, const Data & data); + void set_button_overlay(crepe::GameObject & button_object, const Data & data); + private: - static constexpr crepe::vec2 SIDE_PANEL_OFFSET = {113,0}; + static constexpr crepe::vec2 SIDE_PANEL_OFFSET = {113, 0}; }; |