3#include "spark/core/Export.h"
5#include "experimental/ser/SerializerScheme.h"
6#include "spark/base/Macros.h"
7#include "spark/lib/Uuid.h"
8#include "spark/rtti/HasRtti.h"
22 SPARK_ALLOW_PRIVATE_SERIALIZATION
42 [[nodiscard]]
const lib::Uuid& uuid()
const;
54 [[nodiscard]]
const GameObject* gameObject()
const;
70 virtual void onUpdate(
float dt) { SPARK_UNUSED(dt); }
A component that can be attached to a GameObject to provide additional functionality.
Definition Component.h:20
virtual void onDetach()
Method called when the component is detached from a GameObject.
Definition Component.h:75
virtual void onAttach()
Method called when the component is attached to a GameObject.
Definition Component.h:64
virtual void onUpdate(float dt)
Method called on every frame.
Definition Component.h:70
virtual void render() const
Renders the component.
Definition Component.h:59
A GameObject is any object in the game. It contains a list of components that provides functionality ...
Definition GameObject.h:26
A 128-bit universally unique identifier (UUID).
Definition Uuid.h:22
The class anything using the RTTI should implement.
Definition HasRtti.h:16