17 virtual void Create()
override;
19 virtual void Tick(
float deltaTime)
override;
20 virtual void EditorTick(
float deltaTime)
override;
24 void SetValue(
float value);
25 float GetValue()
const;
26 void SetMinValue(
float min);
27 float GetMinValue()
const;
28 void SetMaxValue(
float max);
29 float GetMaxValue()
const;
30 void SetStep(
float step);
31 float GetStep()
const;
34 void SetPrefix(
const std::string& prefix);
35 const std::string& GetPrefix()
const;
36 void SetSuffix(
const std::string& suffix);
37 const std::string& GetSuffix()
const;
40 void SetBackgroundColor(glm::vec4 color);
41 glm::vec4 GetBackgroundColor();
42 void SetTextColor(glm::vec4 color);
43 glm::vec4 GetTextColor();
44 void SetButtonColor(glm::vec4 color);
45 glm::vec4 GetButtonColor();
51 bool IsEditing()
const;
55 Quad* GetBackground();
56 Text* GetTextWidget();
57 Button* GetIncrementButton();
58 Button* GetDecrementButton();
64 void UpdateAppearance();
70 float mMinValue = 0.0f;
71 float mMaxValue = 100.0f;
77 int32_t mDecimalPlaces = 0;
81 glm::vec4 mBackgroundColor = { 0.2f, 0.2f, 0.2f, 1.0f };
82 glm::vec4 mTextColor = { 1.0f, 1.0f, 1.0f, 1.0f };
83 glm::vec4 mButtonColor = { 0.35f, 0.35f, 0.35f, 1.0f };
84 float mButtonWidth = 20.0f;
88 bool mEditing =
false;
89 float mValueBeforeEdit = 0.0f;
92 Quad* mBackground =
nullptr;