From 509fb6ebdd27bc75375c1c51024ea906e25032c0 Mon Sep 17 00:00:00 2001 From: Loek Le Blansch Date: Sun, 6 Oct 2024 13:45:05 +0200 Subject: WIP more code style enforcements --- mwe/ecs-homemade/inc/ComponentManager.hpp | 3 ++- mwe/ecs-homemade/inc/GameObjectMax.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'mwe/ecs-homemade/inc') diff --git a/mwe/ecs-homemade/inc/ComponentManager.hpp b/mwe/ecs-homemade/inc/ComponentManager.hpp index 161ce71..d6da8e8 100644 --- a/mwe/ecs-homemade/inc/ComponentManager.hpp +++ b/mwe/ecs-homemade/inc/ComponentManager.hpp @@ -42,7 +42,8 @@ void ComponentManager::DeleteComponentsById(std::uint32_t id) { } } -template void ComponentManager::DeleteComponents() { +template +void ComponentManager::DeleteComponents() { std::type_index type = typeid( T); //Determine the type of T (this is used as the key of the unordered_map<>) diff --git a/mwe/ecs-homemade/inc/GameObjectMax.h b/mwe/ecs-homemade/inc/GameObjectMax.h index c88a834..3029053 100644 --- a/mwe/ecs-homemade/inc/GameObjectMax.h +++ b/mwe/ecs-homemade/inc/GameObjectMax.h @@ -7,7 +7,8 @@ class GameObject { public: GameObject(std::uint32_t id, std::string name, std::string tag, int layer); - template void AddComponent(Args &&... args); + template + void AddComponent(Args &&... args); std::uint32_t mId; std::string mName; -- cgit v1.2.3