From 106dfe48c40fdb24b7f5e8a84c992d15363a38d9 Mon Sep 17 00:00:00 2001 From: chai Date: Fri, 24 Aug 2018 20:26:18 +0800 Subject: -some file --- src/libjin/Utils/Component/Component.h | 30 ------------------------- src/libjin/Utils/Component/GameObject.h | 40 --------------------------------- 2 files changed, 70 deletions(-) delete mode 100644 src/libjin/Utils/Component/Component.h delete mode 100644 src/libjin/Utils/Component/GameObject.h (limited to 'src/libjin/Utils/Component') diff --git a/src/libjin/Utils/Component/Component.h b/src/libjin/Utils/Component/Component.h deleted file mode 100644 index f63fb59..0000000 --- a/src/libjin/Utils/Component/Component.h +++ /dev/null @@ -1,30 +0,0 @@ -#ifndef __JIN_TOOLS_COMPONENT_H -#define __JIN_TOOLS_COMPONENT_H -#include "../../modules.h" -#if JIN_MODULES_TOOLS && JIN_TOOLS_COMPONENT - -namespace jin -{ -namespace utils -{ - - class GameObject; - - class Component - { - public: - Component(GameObject* obj) - : gameObject(obj) - {} - - virtual void update(float dt) = 0; - - private: - GameObject* gameObject; - }; - -} // tools -} // jin - -#endif // JIN_MODULES_TOOLS && JIN_TOOLS_COMPONENT -#endif // __JIN_TOOLS_COMPONENT_H \ No newline at end of file diff --git a/src/libjin/Utils/Component/GameObject.h b/src/libjin/Utils/Component/GameObject.h deleted file mode 100644 index e4f3aa5..0000000 --- a/src/libjin/Utils/Component/GameObject.h +++ /dev/null @@ -1,40 +0,0 @@ -#ifndef __JIN_TOOLS_GAMEOBJECT_H -#define __JIN_TOOLS_GAMEOBJECT_H -#include "../../modules.h" -#if JIN_MODULES_TOOLS && JIN_TOOLS_COMPONENT - -#include -#include "Component.h" - -namespace jin -{ -namespace utils -{ - - class GameObject - { - public: - - GameObject() - : components() - { - } - - virtual void update(float dt) - { - for each (Component* component in components) - component->update(dt); - } - - virtual void draw() = 0; - - protected: - - std::vector components; - }; - -} // tools -} // jin - -#endif // JIN_MODULES_TOOLS && JIN_TOOLS_COMPONENT -#endif // __JIN_TOOLS_GAMEOBJECT_H \ No newline at end of file -- cgit v1.1-26-g67d0