Check if you are playing a game then execute `LUAh_GameQuit` if you are in Command_quit_f and Command_ExitGame_f

This commit is contained in:
Zachary McAlpin 2020-03-15 10:34:43 -05:00
parent 8b7f93d50a
commit 2052ee1144

View file

@ -3574,6 +3574,10 @@ static void Command_Playintro_f(void)
*/
FUNCNORETURN static ATTRNORETURN void Command_Quit_f(void)
{
#ifdef HAVE_BLUA
if (Playing())
LUAh_GameQuit();
#endif
I_Quit();
}
@ -4236,7 +4240,7 @@ void Command_ExitGame_f(void)
INT32 i;
#ifdef HAVE_BLUA
if (maptol)
if (Playing())
LUAh_GameQuit();
#endif