From 7c580462b3797029d3655f26db9894c7e9075649 Mon Sep 17 00:00:00 2001 From: Sara Gerretsen Date: Mon, 22 Sep 2025 21:42:40 +0200 Subject: [PATCH] chore: translated more C stuff to C++ in main.cpp --- src/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 8d0d60a..136b421 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -93,7 +93,7 @@ void InitClay() { Clay_Initialize(clayPrimaryArena, { (float)screenWidth, (float)screenHeight }, { HandleClayErrors }); Clay_SetMeasureTextFunction(MeasureText, resources::fonts); Clay_SetLayoutDimensions({ (float)screenWidth, (float)screenHeight }); - float x, y; + float x{ 0 }, y{ 0 }; SDL_GetMouseState(&x, &y); Clay_SetPointerState((Clay_Vector2) { x, y }, false); } @@ -103,7 +103,7 @@ int main(int argc, char *argv[]) { resources::LoadResources(); LogOutputResolution(); InitClay(); - backendData = (Clay_SDL3RendererData) { renderer, resources::textEngine, resources::fonts }; + backendData = { renderer, resources::textEngine, resources::fonts }; SDL_Event event; uint64_t startFrameTime = SDL_GetTicksNS(); double deltaTime = 0.0;