mirror of
https://github.com/HowestDAE/dae16-VerhulstBram.git
synced 2025-12-18 09:59:20 +01:00
Add Text rendering and Hull / Fuel Meters
This commit is contained in:
20
Game/Gui/GuiText.h
Normal file
20
Game/Gui/GuiText.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
#include "GuiElement.h"
|
||||
#include "Text.h"
|
||||
#include "Texture.h"
|
||||
|
||||
class GuiText : public GuiElement {
|
||||
public:
|
||||
GuiText(const Vector2f& position, const std::string& text, const std::string& fontPath, int size, const Color4f& color);
|
||||
GuiText();
|
||||
|
||||
void Draw() const override;
|
||||
void Update(float elapsedSec) override;
|
||||
|
||||
void ChangeText(const std::string& text) const;
|
||||
|
||||
~GuiText() override;
|
||||
private:
|
||||
Vector2f m_Position;
|
||||
Text* m_Text;
|
||||
};
|
||||
Reference in New Issue
Block a user