aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/system
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-16 16:46:18 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-16 16:46:18 +0100
commitfc5dfd2873279d5003f8a02187a71b05a44892fa (patch)
treee36d40a1b26e9d4900b582c5f06c4d1dc2858d34 /src/crepe/system
parent572741fc845f430d225a4611a94aae7a2a544d12 (diff)
final touchups 2 for #26loek/cleanup
Diffstat (limited to 'src/crepe/system')
-rw-r--r--src/crepe/system/ParticleSystem.h2
-rw-r--r--src/crepe/system/ScriptSystem.cpp5
2 files changed, 2 insertions, 5 deletions
diff --git a/src/crepe/system/ParticleSystem.h b/src/crepe/system/ParticleSystem.h
index 0a2dde1..c647284 100644
--- a/src/crepe/system/ParticleSystem.h
+++ b/src/crepe/system/ParticleSystem.h
@@ -4,8 +4,6 @@
#include "System.h"
-#include "System.h"
-
namespace crepe {
class ParticleEmitter;
diff --git a/src/crepe/system/ScriptSystem.cpp b/src/crepe/system/ScriptSystem.cpp
index f4a826b..c4d724c 100644
--- a/src/crepe/system/ScriptSystem.cpp
+++ b/src/crepe/system/ScriptSystem.cpp
@@ -18,10 +18,9 @@ void ScriptSystem::update() {
for (auto & script_ref : scripts) {
Script & script = script_ref.get();
- BehaviorScript & component = *script.parent_ref;
- if (!component.initialized) {
+ if (!script.initialized) {
script.init();
- component.initialized = true;
+ script.initialized = true;
}
script.update();
}