Update exit message

This commit is contained in:
sam-astro 2022-05-27 19:43:39 -04:00
parent 1188412769
commit 582656be7b
2 changed files with 5 additions and 5 deletions

View File

@ -940,7 +940,7 @@ int main(int argc, char* argv[])
else
{ // If no script is provided as an argument throw error
LogWarning("No script provided! Please drag and drop .ZS file over interpreter executable file, or provide it's path as a command-line argument.");
cout << "Press Enter to Continue";
InterpreterLog("Press Enter to Exit...");
cin.ignore();
exit(1);
}
@ -965,7 +965,7 @@ int main(int argc, char* argv[])
// Entire script has been run, exit.
#if DEVELOPER_MESSAGES // If built with developer messages, then verify exit
cout << "Press Enter to Continue";
InterpreterLog("Press Enter to Exit...");
cin.ignore();
exit(1);
#else
@ -977,14 +977,14 @@ int main(int argc, char* argv[])
if (a == "-ve") // If the '-ve' (verify exit) option is used, ask for verification on exit
{
cout << "Press Enter to Continue";
InterpreterLog("Press Enter to Exit...");
cin.ignore();
exit(1);
}
}
else if (AnyAsBool(GetVariableValue("EXIT_WHEN_DONE", globalVariableValues)) == false)
{
cout << "Press Enter to Continue";
InterpreterLog("Press Enter to Exit...");
cin.ignore();
exit(1);
}

View File

@ -207,7 +207,7 @@ int LogCriticalError(const string& errorText)
PrintColored("ZSharp: ", yellowFGColor, "", true);
PrintColored(errorText, redFGColor, "", true);
cerr << std::endl;
cout << "Press Enter to Continue";
InterpreterLog("Press Enter to Exit...");
cin.ignore();
exit(1);
//cerr << "\x1B[34m[" + to_string(Hour) + ":" + to_string(Min) + ":" + to_string(Sec) + "] \x1B[33mZSharp: \x1B[31mERROR: " << errorText << "\033[0m\t\t" << endl;