From c767ef1e3d1d78e50eb1b6d9824b1c8961d68524 Mon Sep 17 00:00:00 2001 From: Max-001 <80035972+Max-001@users.noreply.github.com> Date: Sat, 5 Oct 2024 12:07:18 +0200 Subject: First setup --- mwe/ecs-memory-efficient/inc/GameObjectMax.hpp | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'mwe/ecs-memory-efficient/inc/GameObjectMax.hpp') diff --git a/mwe/ecs-memory-efficient/inc/GameObjectMax.hpp b/mwe/ecs-memory-efficient/inc/GameObjectMax.hpp index 1e952ba..aac9811 100644 --- a/mwe/ecs-memory-efficient/inc/GameObjectMax.hpp +++ b/mwe/ecs-memory-efficient/inc/GameObjectMax.hpp @@ -1,6 +1,16 @@ #include "ComponentManager.h" -template -void GameObject::AddComponent(Args&&... args) { - ComponentManager::GetInstance().AddComponent(mId, std::forward(args)...); +template +void GameObject::addSpriteComponent(Args&&... args) { + ComponentManager::GetInstance().addSpriteComponent(std::forward(args)...); +} + +template +void GameObject::addRigidbodyComponent(Args&&... args) { + ComponentManager::GetInstance().addRigidbodyComponent(std::forward(args)...); +} + +template +void GameObject::addColiderComponent(Args&&... args) { + ComponentManager::GetInstance().addColiderComponent(std::forward(args)...); } -- cgit v1.2.3