diff options
author | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-09 20:15:41 +0100 |
---|---|---|
committer | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-09 20:15:41 +0100 |
commit | a597b0059f30e9d56331c6ece34fdcabb4028616 (patch) | |
tree | 09da85838764dc25f020a14a17937267a686590c /src/crepe/system/RenderSystem.cpp | |
parent | 4d74c80d9c3c9fdca9b07d960a1f9fd3e38cdfad (diff) |
making rendering fonts and UI
Diffstat (limited to 'src/crepe/system/RenderSystem.cpp')
-rw-r--r-- | src/crepe/system/RenderSystem.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/crepe/system/RenderSystem.cpp b/src/crepe/system/RenderSystem.cpp index 26f2c85..74fed26 100644 --- a/src/crepe/system/RenderSystem.cpp +++ b/src/crepe/system/RenderSystem.cpp @@ -27,7 +27,7 @@ void RenderSystem::present_screen() { ctx.present_screen(); } -SDLContext::CameraValues RenderSystem::update_camera() { +SDLContext::CameraValues & RenderSystem::update_camera() { ComponentManager & mgr = this->mediator.component_manager; SDLContext & ctx = this->mediator.sdl_context; RefVector<Camera> cameras = mgr.get_components_by_type<Camera>(); @@ -38,7 +38,7 @@ SDLContext::CameraValues RenderSystem::update_camera() { if (!cam.active) continue; const Transform & transform = mgr.get_components_by_id<Transform>(cam.game_object_id).front().get(); - SDLContext::CameraValues cam_val = ctx.set_camera(cam); + SDLContext::CameraValues & cam_val = ctx.set_camera(cam); cam_val.cam_pos = transform.position + cam.data.postion_offset; return cam_val; } |