From 4c74d258404d13affe2adb294d14fb6f9f72838d Mon Sep 17 00:00:00 2001 From: jacob1 Date: Thu, 26 Jan 2023 22:40:58 -0500 Subject: [PATCH] Fix graphical artifacts sometimes showing up with ptsave startup arg --- src/PowderToySDL.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/PowderToySDL.cpp b/src/PowderToySDL.cpp index 6e4bb29c4..c6c7e594c 100644 --- a/src/PowderToySDL.cpp +++ b/src/PowderToySDL.cpp @@ -890,6 +890,7 @@ int main(int argc, char * argv[]) auto ptsaveArg = arguments["ptsave"]; if (ptsaveArg.has_value()) { + engine->g->Clear(); engine->g->fillrect((engine->GetWidth()/2)-101, (engine->GetHeight()/2)-26, 202, 52, 0, 0, 0, 210); engine->g->drawrect((engine->GetWidth()/2)-100, (engine->GetHeight()/2)-25, 200, 50, 255, 255, 255, 180); engine->g->drawtext((engine->GetWidth()/2)-(Graphics::textwidth("Loading save...")/2), (engine->GetHeight()/2)-5, "Loading save...", style::Colour::InformationTitle.Red, style::Colour::InformationTitle.Green, style::Colour::InformationTitle.Blue, 255);