aboutsummaryrefslogtreecommitdiff
path: root/src/crepe
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe')
-rw-r--r--src/crepe/api/LoopManager.cpp5
-rw-r--r--src/crepe/api/LoopManager.h2
-rw-r--r--src/crepe/api/Scene.h3
-rw-r--r--src/crepe/api/Script.cpp1
-rw-r--r--src/crepe/api/Script.h4
-rw-r--r--src/crepe/manager/ComponentManager.cpp2
-rw-r--r--src/crepe/manager/Manager.cpp3
-rw-r--r--src/crepe/manager/Manager.h3
-rw-r--r--src/crepe/manager/Mediator.h4
-rw-r--r--src/crepe/manager/SaveManager.cpp4
-rw-r--r--src/crepe/system/PhysicsSystem.cpp2
-rw-r--r--src/crepe/system/RenderSystem.cpp2
-rw-r--r--src/crepe/system/ScriptSystem.cpp2
13 files changed, 16 insertions, 21 deletions
diff --git a/src/crepe/api/LoopManager.cpp b/src/crepe/api/LoopManager.cpp
index b277185..731cfb7 100644
--- a/src/crepe/api/LoopManager.cpp
+++ b/src/crepe/api/LoopManager.cpp
@@ -22,9 +22,7 @@ LoopManager::LoopManager() {
this->load_system<ScriptSystem>();
}
-void LoopManager::process_input() {
- this->sdl_context.handle_events(this->game_running);
-}
+void LoopManager::process_input() { this->sdl_context.handle_events(this->game_running); }
void LoopManager::start() {
this->setup();
@@ -69,4 +67,3 @@ void LoopManager::render() {
}
void LoopManager::update() {}
-
diff --git a/src/crepe/api/LoopManager.h b/src/crepe/api/LoopManager.h
index 6ea5ccc..d8910a0 100644
--- a/src/crepe/api/LoopManager.h
+++ b/src/crepe/api/LoopManager.h
@@ -2,10 +2,10 @@
#include <memory>
+#include "../facade/SDLContext.h"
#include "../manager/ComponentManager.h"
#include "../manager/SceneManager.h"
#include "../system/System.h"
-#include "../facade/SDLContext.h"
#include "LoopTimer.h"
diff --git a/src/crepe/api/Scene.h b/src/crepe/api/Scene.h
index 66dad17..9f1e8ce 100644
--- a/src/crepe/api/Scene.h
+++ b/src/crepe/api/Scene.h
@@ -2,8 +2,8 @@
#include <string>
-#include "../util/OptionalRef.h"
#include "../manager/Mediator.h"
+#include "../util/OptionalRef.h"
namespace crepe {
@@ -37,6 +37,7 @@ public:
// TODO: Late references should ALWAYS be private! This is currently kept as-is so unit tests
// keep passing, but this reference should not be directly accessible by the user!!!
+
protected:
/**
* \name Late references
diff --git a/src/crepe/api/Script.cpp b/src/crepe/api/Script.cpp
index a27838e..4091fd4 100644
--- a/src/crepe/api/Script.cpp
+++ b/src/crepe/api/Script.cpp
@@ -25,4 +25,3 @@ void Script::set_next_scene(const string & name) {
SceneManager & mgr = mediator.scene_manager;
mgr.set_next_scene(name);
}
-
diff --git a/src/crepe/api/Script.h b/src/crepe/api/Script.h
index e1f86b2..1b339b0 100644
--- a/src/crepe/api/Script.h
+++ b/src/crepe/api/Script.h
@@ -2,10 +2,10 @@
#include <vector>
+#include "../manager/EventManager.h"
+#include "../manager/Mediator.h"
#include "../types.h"
#include "../util/OptionalRef.h"
-#include "../manager/Mediator.h"
-#include "../manager/EventManager.h"
namespace crepe {
diff --git a/src/crepe/manager/ComponentManager.cpp b/src/crepe/manager/ComponentManager.cpp
index 5a96158..80cf8b4 100644
--- a/src/crepe/manager/ComponentManager.cpp
+++ b/src/crepe/manager/ComponentManager.cpp
@@ -1,6 +1,6 @@
#include "../api/GameObject.h"
-#include "../util/Log.h"
#include "../types.h"
+#include "../util/Log.h"
#include "ComponentManager.h"
diff --git a/src/crepe/manager/Manager.cpp b/src/crepe/manager/Manager.cpp
index fe7c936..1182785 100644
--- a/src/crepe/manager/Manager.cpp
+++ b/src/crepe/manager/Manager.cpp
@@ -2,5 +2,4 @@
using namespace crepe;
-Manager::Manager(Mediator & mediator) : mediator(mediator) { }
-
+Manager::Manager(Mediator & mediator) : mediator(mediator) {}
diff --git a/src/crepe/manager/Manager.h b/src/crepe/manager/Manager.h
index 9adfd0b..4f21ef4 100644
--- a/src/crepe/manager/Manager.h
+++ b/src/crepe/manager/Manager.h
@@ -13,5 +13,4 @@ protected:
Mediator & mediator;
};
-}
-
+} // namespace crepe
diff --git a/src/crepe/manager/Mediator.h b/src/crepe/manager/Mediator.h
index a91509e..71bd1c9 100644
--- a/src/crepe/manager/Mediator.h
+++ b/src/crepe/manager/Mediator.h
@@ -3,8 +3,8 @@
#include "../util/OptionalRef.h"
// TODO: remove these singletons:
-#include "SaveManager.h"
#include "EventManager.h"
+#include "SaveManager.h"
namespace crepe {
@@ -30,4 +30,4 @@ struct Mediator {
OptionalRef<EventManager> event_manager = EventManager::get_instance();
};
-}
+} // namespace crepe
diff --git a/src/crepe/manager/SaveManager.cpp b/src/crepe/manager/SaveManager.cpp
index 121d017..d4ed1c1 100644
--- a/src/crepe/manager/SaveManager.cpp
+++ b/src/crepe/manager/SaveManager.cpp
@@ -1,7 +1,7 @@
+#include "../ValueBroker.h"
+#include "../api/Config.h"
#include "../facade/DB.h"
#include "../util/Log.h"
-#include "../api/Config.h"
-#include "../ValueBroker.h"
#include "SaveManager.h"
diff --git a/src/crepe/system/PhysicsSystem.cpp b/src/crepe/system/PhysicsSystem.cpp
index eba9dfa..bebcf3d 100644
--- a/src/crepe/system/PhysicsSystem.cpp
+++ b/src/crepe/system/PhysicsSystem.cpp
@@ -1,10 +1,10 @@
#include <cmath>
-#include "../manager/ComponentManager.h"
#include "../api/Config.h"
#include "../api/Rigidbody.h"
#include "../api/Transform.h"
#include "../api/Vector2.h"
+#include "../manager/ComponentManager.h"
#include "PhysicsSystem.h"
diff --git a/src/crepe/system/RenderSystem.cpp b/src/crepe/system/RenderSystem.cpp
index 4e97b3e..0ad685c 100644
--- a/src/crepe/system/RenderSystem.cpp
+++ b/src/crepe/system/RenderSystem.cpp
@@ -5,12 +5,12 @@
#include <stdexcept>
#include <vector>
-#include "../manager/ComponentManager.h"
#include "../api/Camera.h"
#include "../api/ParticleEmitter.h"
#include "../api/Sprite.h"
#include "../api/Transform.h"
#include "../facade/SDLContext.h"
+#include "../manager/ComponentManager.h"
#include "RenderSystem.h"
diff --git a/src/crepe/system/ScriptSystem.cpp b/src/crepe/system/ScriptSystem.cpp
index 2e16eb0..d6b2ca1 100644
--- a/src/crepe/system/ScriptSystem.cpp
+++ b/src/crepe/system/ScriptSystem.cpp
@@ -1,6 +1,6 @@
-#include "../manager/ComponentManager.h"
#include "../api/BehaviorScript.h"
#include "../api/Script.h"
+#include "../manager/ComponentManager.h"
#include "ScriptSystem.h"