21 static const std::vector<ScreenComponent*>&
instances() {
return _instances; }
31 float scale()
const {
return _scale; }
36 inline static std::vector<ScreenComponent*> _instances;
40 bool _screenSpace =
true;
Component(IComponentSystem *system, Entity *entity)
IComponentSystem * system() const
ECS entity — a GraphNode that hosts components defining its behavior.
const Vector2 & resolution() const
ScreenComponent(IComponentSystem *system, Entity *entity)
void initializeComponentData() override
~ScreenComponent() override
void updateScaleFromWindow(int windowWidth, int windowHeight)
static const std::vector< ScreenComponent * > & instances()
void setScreenSpace(const bool value)
const Vector2 & referenceResolution() const
void setReferenceResolution(const Vector2 &value)
2D vector for UV coordinates, screen positions, and 2D math.