Make noises on the password entry screen

This commit is contained in:
fickleheart 2019-03-10 17:36:16 -05:00
parent 4a8d682b43
commit 048ce8496f
1 changed files with 22 additions and 4 deletions

View File

@ -4001,11 +4001,23 @@ static void HandlePacketFromAwayNode(SINT8 node)
cl_mode = CL_CHALLENGE;
if (cl_challengeattempted == 2)
switch (cl_challengeattempted)
{
// We already sent a correct password, so throw it back up again.
D_ComputeChallengeAnswer(cl_challengequestion, cl_challengepassword, cl_challengeanswer);
cl_mode = CL_ASKJOIN;
case 2:
// We already sent a correct password, so throw it back up again.
D_ComputeChallengeAnswer(cl_challengequestion, cl_challengepassword, cl_challengeanswer);
cl_mode = CL_ASKJOIN;
break;
case 1:
// We entered the wrong password!
S_StartSound(NULL, sfx_s26d);
break;
default:
// First entry to the password screen.
S_StartSound(NULL, sfx_s224);
break;
}
}
break;
@ -4064,6 +4076,9 @@ static void HandlePacketFromAwayNode(SINT8 node)
break;
}
if (cl_challengeattempted == 1) // Successful password noise.
S_StartSound(NULL, sfx_s221);
cl_challengeattempted = 2;
CONS_Printf("trying to download\n");
if (CL_SendRequestFile())
@ -4085,6 +4100,9 @@ static void HandlePacketFromAwayNode(SINT8 node)
if (cl_mode != CL_WAITJOINRESPONSE)
break;
if (cl_challengeattempted == 1) // Successful password noise.
S_StartSound(NULL, sfx_s221);
if (client)
{
maketic = gametic = neededtic = (tic_t)LONG(netbuffer->u.servercfg.gametic);