diff --git a/Aeon/Aeon.hpp b/Aeon/Aeon.hpp index ab9073f..4f51259 100644 --- a/Aeon/Aeon.hpp +++ b/Aeon/Aeon.hpp @@ -9,11 +9,16 @@ #include "Aeon/Core/GameLayer.hpp" #include "Aeon/Input/Input.hpp" -namespace Core { +namespace Core +{ // NOTE: Derivations / children of "App" cannot attatch // event listeners to themselves, the programmer must // first add a gamelayer to handle events + +// App stores the GLOBAL gamestate +// It is OK to store this globally +// every component needs to use state class App : public EventListener { public: diff --git a/Aeon/Core/Events.cpp b/Aeon/Core/Events.cpp index dbb6ca5..5c21abc 100644 --- a/Aeon/Core/Events.cpp +++ b/Aeon/Core/Events.cpp @@ -7,6 +7,9 @@ using Core::EventListener; using Core::EventDispatcher; using Core::EventManager; +// TODO: Events should use pre-allocated memory ALWAYS! +// TODO: Look into Bump Allocation + EventListener::EventListener() { diff --git a/Aeon/Core/Events.hpp b/Aeon/Core/Events.hpp index 6c1ab36..37f6eb3 100644 --- a/Aeon/Core/Events.hpp +++ b/Aeon/Core/Events.hpp @@ -22,7 +22,8 @@ #include "Aeon/Singleton.hpp" #include "Aeon/Input/InputMap.hpp" -namespace Core { +namespace Core +{ // THis needs some redesigning so i can do this.AttachSpecificListener(Type, Action, [&] => {...}) // More specifically to support enumerator calling AND custom defined string calling diff --git a/Aeon/Entity/Entity.hpp b/Aeon/Entity/Entity.hpp new file mode 100644 index 0000000..4f2bf95 --- /dev/null +++ b/Aeon/Entity/Entity.hpp @@ -0,0 +1,10 @@ + +namespace EC +{ + +struct Entity +{ + uint32_t id; +}; + +} diff --git a/Aeon/Entity/EntityController.cpp b/Aeon/Entity/EntityController.cpp new file mode 100644 index 0000000..fd40910 --- /dev/null +++ b/Aeon/Entity/EntityController.cpp @@ -0,0 +1,4 @@ + + + + diff --git a/Aeon/Entity/EntityController.hpp b/Aeon/Entity/EntityController.hpp new file mode 100644 index 0000000..464814e --- /dev/null +++ b/Aeon/Entity/EntityController.hpp @@ -0,0 +1,8 @@ + +namespace EC +{ + + + +} + diff --git a/Aeon/Input/Input.hpp b/Aeon/Input/Input.hpp index f19ce08..5cc53ef 100644 --- a/Aeon/Input/Input.hpp +++ b/Aeon/Input/Input.hpp @@ -8,7 +8,8 @@ #include "Aeon/Singleton.hpp" #include "Aeon/Core/Events.hpp" -namespace Input { +namespace Input +{ class InputController : public Helpers::Singleton { diff --git a/Aeon/Singleton.hpp b/Aeon/Singleton.hpp index 5ae6774..c8513a3 100644 --- a/Aeon/Singleton.hpp +++ b/Aeon/Singleton.hpp @@ -1,7 +1,8 @@ #ifndef AEON_SINGLETON_H_ #define AEON_SINGLETON_H_ -namespace Helpers { +namespace Helpers +{ template class Singleton