It seems the console don't close itself when exit the practice mod. Closing the console manually will result in closing the game.
I suppose adding the PostMessage(GetConsoleWindow(), WM_CLOSE, 0, 0); after FreeConsole(); in LabToolConsole::~LabToolConsole(), labtool_manager.cpp can be helpful, but I'm not sure.
// labtool_manager.cpp
LabToolConsole::~LabToolConsole() {
// Other cleanup code...
FreeConsole();
// Additional cleanup code
PostMessage(GetConsoleWindow(), WM_CLOSE, 0, 0);
}```