cl_main.c / CL_ConnectionlessPacket()--------------------------------------------------------------- // server connection if (!strcmp(c, "client_connect")) { if (cls.state == ca_connected) { Com_DPrintf ("Dup connect received. Ignored.\n"); return; //r1: note, next 2 should be redundant with the above global check. } else if (cls.state == ca_disconnected) { //FIXME: this should never happen (disconnecting nukes remote, no remote //= no packet) Com_DPrintf ("Received connect when disconnected. Ignored.\n"); return; } else if (cls.state == ca_active) { Com_DPrintf ("Illegal connect when already connected !! (q2msgs?). Ignored.\n"); return; } Com_DPrintf ("client_connect: new\n"); Netchan_Setup (NS_CLIENT, &cls.netchan, &net_from, cls.serverProtocol, cls.quakePort, 0); MSG_WriteByte (clc_stringcmd); MSG_WriteString ("new"); MSG_EndWriting (&cls.netchan.message); cls.key_dest = key_game; //CL_FixCvarCheats(); send_packet_now = true; cls.state = ca_connected; return; }