| 46 | } |
| 47 | |
| 48 | IClient* xrServer::new_client(SClientConnectData* cl_data) |
| 49 | { |
| 50 | IClient* CL = client_Find_Get(cl_data->clientID); |
| 51 | VERIFY(CL); |
| 52 | |
| 53 | // copy entity |
| 54 | CL->ID = cl_data->clientID; |
| 55 | CL->process_id = cl_data->process_id; |
| 56 | |
| 57 | string64 new_name; |
| 58 | strcpy_s(new_name, cl_data->name); |
| 59 | CL->name = new_name; |
| 60 | CL->pass = cl_data->pass; |
| 61 | |
| 62 | NET_Packet P; |
| 63 | P.B.count = 0; |
| 64 | P.r_pos = 0; |
| 65 | |
| 66 | game->AddDelayedEvent(P, GAME_EVENT_CREATE_CLIENT, 0, CL->ID); |
| 67 | if (client_Count() == 1) |
| 68 | { |
| 69 | Update(); |
| 70 | } |
| 71 | return CL; |
| 72 | } |
| 73 | |
| 74 | void xrServer::AttachNewClient(IClient* CL) |
| 75 | { |
nothing calls this directly
no test coverage detected