diff options
author | jaroWMR <jarorutjes07@gmail.com> | 2024-10-20 16:58:13 +0200 |
---|---|---|
committer | jaroWMR <jarorutjes07@gmail.com> | 2024-10-20 16:58:13 +0200 |
commit | cead795b7ff7135e13caf9ad3b76628070391458 (patch) | |
tree | f91f5e9f6927727367324961e585d049d2947364 /src/crepe/GameObject.cpp | |
parent | d8483cfab70b5aca3baae6e0588924da8b54e090 (diff) |
added collision system and circlecollider
Diffstat (limited to 'src/crepe/GameObject.cpp')
-rw-r--r-- | src/crepe/GameObject.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/crepe/GameObject.cpp b/src/crepe/GameObject.cpp index de3beb6..36eb886 100644 --- a/src/crepe/GameObject.cpp +++ b/src/crepe/GameObject.cpp @@ -1,7 +1,12 @@ #include "GameObject.h" +#include "Transform.h" using namespace crepe; GameObject::GameObject(uint32_t id, std::string name, std::string tag, int layer) - : id(id), name(name), tag(tag), active(true), layer(layer) {} + : id(id), name(name), tag(tag), active(true), layer(layer) +{ + Position pos = {0,0}; + this->add_component<Transform>(pos, 0, 0); +} |