Fix crash when trying to queue cup while highlighting an empty square.

This commit is contained in:
FreakyMutantMan 2025-10-22 11:20:32 -07:00
parent add76b17aa
commit ea8acf33aa

View file

@ -525,7 +525,7 @@ void M_CupSelectHandler(INT32 choice)
{
M_SetMenuDelay(pid);
if (cupgrid.builtgrid[CUPMENU_CURSORID] == &dummy_lostandfound)
if ((cupgrid.builtgrid[CUPMENU_CURSORID] == &dummy_lostandfound) || (cupgrid.builtgrid[CUPMENU_CURSORID] == NULL))
S_StartSound(NULL, sfx_gshe7);
else if (!M_IsCupQueueable(cupgrid.builtgrid[CUPMENU_CURSORID]))