#pragma region Hidden Setup Stuff #define OLC_PGE_APPLICATION #include "olcPixelGameEngine.h" using namespace olc; enum Run{ FILE1, FILE2 }; // Override base class with your custom functionality class AoC2023 : public olc::PixelGameEngine { std::vectorlines; bool waitForRender=false; void wait(int pauseMs=0){ waitForRender=true; while(waitForRender); std::this_thread::sleep_for(std::chrono::milliseconds(pauseMs)); } #pragma endregion const int DAY = 11; Run runInput=FILE2; std::vectorspace; std::vectorgalaxies; std::vectorwalkPath; void doStuff(){ while(true){ //lines is accessible as a global. for(std::string&line:lines){ space.push_back(line); bool allDots=true; for(int i=0;istartingPos.x){ startingPos.x++; }else{ startingPos.x--; } if(space[startingPos.y][startingPos.x]=='.'||space[startingPos.y][startingPos.x]=='#'){ sum++; }else{ sum+=999999; } }else{ if(galaxy2.y>startingPos.y){ startingPos.y++; }else{ startingPos.y--; } if(space[startingPos.y][startingPos.x]=='.'||space[startingPos.y][startingPos.x]=='#'){ sum++; }else{ sum+=999999; } } walkPath.push_back(startingPos); } wait(1); } index++; } std::cout<