aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/Metadata.h
diff options
context:
space:
mode:
authormax-001 <maxsmits21@kpnmail.nl>2024-11-06 14:03:34 +0100
committermax-001 <maxsmits21@kpnmail.nl>2024-11-06 14:03:34 +0100
commitdb5a3668aa4b3919ee8dce7ed0872aa5707f80ff (patch)
tree6169d98300a2b26d84a85961a66e222a2ca2e5ca /src/crepe/Metadata.h
parent64ca0a7ae147c7d98ff092e04d86468ace6ea2a1 (diff)
Added Doxygen comments
Diffstat (limited to 'src/crepe/Metadata.h')
-rw-r--r--src/crepe/Metadata.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/crepe/Metadata.h b/src/crepe/Metadata.h
index 1577987..d52ab67 100644
--- a/src/crepe/Metadata.h
+++ b/src/crepe/Metadata.h
@@ -7,16 +7,36 @@
namespace crepe {
+/**
+ * \brief Metadata component
+ *
+ * This class represents the Metadata component. It stores the name, tag, parent
+ * and children of a GameObject.
+ */
class Metadata : public Component {
public:
+ /**
+ * \param game_object_id The id of the GameObject this component belongs to
+ * \param name The name of the GameObject
+ * \param tag The tag of the GameObject
+ */
Metadata(uint32_t game_object_id, const std::string & name,
const std::string & tag);
+ /**
+ * \brief Get the maximum number of instances for this component
+ *
+ * \return The maximum number of instances for this component
+ */
virtual int get_instances_max() const { return 1; }
public:
+ //! The name of the GameObject
std::string name;
+ //! The tag of the GameObject
std::string tag;
+ //! The id of the parent GameObject (-1 if no parent)
uint32_t parent = -1;
+ //! The ids of the children GameObjects
std::vector<uint32_t> children;
};