aboutsummaryrefslogtreecommitdiffstats
path: root/yage/entity/component.h
diff options
context:
space:
mode:
authorYann Herklotz <ymherklotz@gmail.com>2018-06-23 16:06:42 +0100
committerGitHub <noreply@github.com>2018-06-23 16:06:42 +0100
commit11a6d07652c98b13be6d8097e389480453a7c568 (patch)
tree3f06a7d35e8ec647041fccea90d5d763ebe6849f /yage/entity/component.h
parentb1673de1b46bd2e566b7c66197ad989d0323f061 (diff)
parent93c8bfea8b5bcfc0d6513d93cec0eafe82dc465a (diff)
downloadYAGE-master.tar.gz
YAGE-master.zip
Merge pull request #20 from ymherklotz/developHEADmaster
Develop
Diffstat (limited to 'yage/entity/component.h')
-rw-r--r--yage/entity/component.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/yage/entity/component.h b/yage/entity/component.h
index a21409ff..3f2b3a81 100644
--- a/yage/entity/component.h
+++ b/yage/entity/component.h
@@ -28,13 +28,21 @@ private:
template <typename T>
class Component : public BaseComponent
{
+private:
GroupId getGroup() override;
};
class ComponentGroup
{
public:
- std::vector<std::unique_ptr<BaseComponent>> components_;
+ typedef std::vector<std::unique_ptr<BaseComponent>> Container;
+
+ ComponentGroup &add(std::unique_ptr<BaseComponent> &&component);
+ Container::iterator begin();
+ Container::iterator end();
+
+private:
+ Container components_;
};
template <typename T>