2024-02-25 14:46:47 +00:00
|
|
|
#pragma once
|
2023-06-20 04:33:09 +00:00
|
|
|
|
|
|
|
#include "StarPane.hpp"
|
|
|
|
#include "StarMainInterfaceTypes.hpp"
|
|
|
|
|
|
|
|
namespace Star {
|
|
|
|
|
|
|
|
STAR_CLASS(Player);
|
|
|
|
STAR_CLASS(UniverseClient);
|
|
|
|
STAR_CLASS(StatusPane);
|
|
|
|
|
|
|
|
class StatusPane : public Pane {
|
|
|
|
public:
|
|
|
|
StatusPane(MainInterfacePaneManager* paneManager, UniverseClientPtr client);
|
|
|
|
|
|
|
|
virtual PanePtr createTooltip(Vec2I const& screenPosition) override;
|
|
|
|
|
|
|
|
protected:
|
|
|
|
virtual void renderImpl() override;
|
2023-07-20 14:58:49 +00:00
|
|
|
virtual void update(float dt) override;
|
2023-06-20 04:33:09 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
struct StatusEffectIndicator {
|
|
|
|
String icon;
|
|
|
|
Maybe<float> durationPercentage;
|
|
|
|
String label;
|
|
|
|
RectF screenRect;
|
|
|
|
};
|
|
|
|
|
|
|
|
MainInterfacePaneManager* m_paneManager;
|
|
|
|
UniverseClientPtr m_client;
|
|
|
|
PlayerPtr m_player;
|
|
|
|
|
|
|
|
GuiContext* m_guiContext;
|
|
|
|
List<StatusEffectIndicator> m_statusIndicators;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|