aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/Script.hpp
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/api/Script.hpp
parent572741fc845f430d225a4611a94aae7a2a544d12 (diff)
final touchups 2 for #26loek/cleanup
Diffstat (limited to 'src/crepe/api/Script.hpp')
-rw-r--r--src/crepe/api/Script.hpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/crepe/api/Script.hpp b/src/crepe/api/Script.hpp
index c4e07e8..a064a90 100644
--- a/src/crepe/api/Script.hpp
+++ b/src/crepe/api/Script.hpp
@@ -20,10 +20,9 @@ T & Script::get_component() const {
template <typename T>
std::vector<std::reference_wrapper<T>> Script::get_components() const {
- auto & parent = *this->parent_ref;
auto & mgr = *this->component_manager_ref;
- return mgr.get_components_by_id<T>(parent.game_object_id);
+ return mgr.get_components_by_id<T>(this->game_object_id);
}
} // namespace crepe