diff options
author | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-17 15:58:03 +0100 |
---|---|---|
committer | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-17 15:58:03 +0100 |
commit | 23eef97ed3fc57fdd619769a74d0abfa7f657714 (patch) | |
tree | e4aa23ac227ac1b1355e6e9d54c405c8a01cc017 /src | |
parent | 8d53634e2f47a616ff90f114fe1afbc2ba4df094 (diff) |
merged master
Diffstat (limited to 'src')
-rw-r--r-- | src/crepe/api/Config.h | 4 | ||||
-rw-r--r-- | src/crepe/system/RenderSystem.cpp | 3 |
2 files changed, 2 insertions, 5 deletions
diff --git a/src/crepe/api/Config.h b/src/crepe/api/Config.h index 074c113..6b9e3ca 100644 --- a/src/crepe/api/Config.h +++ b/src/crepe/api/Config.h @@ -46,10 +46,6 @@ struct Config final { std::string location = "save.crepe.db"; } savemgr; - struct { - unsigned int size = 16; - } font; - //! physics-related settings struct { /** diff --git a/src/crepe/system/RenderSystem.cpp b/src/crepe/system/RenderSystem.cpp index 684d798..4082591 100644 --- a/src/crepe/system/RenderSystem.cpp +++ b/src/crepe/system/RenderSystem.cpp @@ -85,7 +85,8 @@ void RenderSystem::render_text() { for (Text & text : texts) { if (!text.active) continue; - if (!text.font.has_value()) text.font = ctx.get_font_from_name(text.font_family); + if (!text.font.has_value()) + text.font.emplace(ctx.get_font_from_name(text.font_family)); if (!text.font.has_value()) continue; const Font & font = resource_manager.get<Font>(text.font.value()); |