MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / InitPilotTrackerClient

Function InitPilotTrackerClient

netcon/mtclient/mtpilottracker.cpp:235–256  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

233extern PollUI_fp DLLPollUI;
234
235int InitPilotTrackerClient() {
236
237 D3WriteState = STATE_IDLE;
238 D3ReadState = STATE_IDLE;
239
240 ReadD3Pilot = nullptr;
241 ValidState = VALID_STATE_IDLE;
242
243 VersionState = VERSION_STATE_IDLE;
244
245 srand(DLLtimer_GetTime());
246 ValidSecurity = (uint32_t)rand();
247 // Build the request packet
248 PacketHeader.type = UNT_LOGIN_AUTH_REQUEST; // UNT_VALIDAT_ID_REQUEST;
249 PacketHeader.len = INTEL_SHORT(PACKED_HEADER_ONLY_SIZE + sizeof(validate_id_request));
250 ValidIDReq = (validate_id_request *)&PacketHeader.data;
251
252 d3_pr = (pilot_request *)&d3_pilot_req.data;
253
254 DLLnw_RegisterCallback(HandlePilotData, PXO_NETID_USER_TRACKER);
255 return 1;
256}
257
258// Returns:
259//-3 Error -- Called with NULL, but no request is waiting

Callers 1

InitMTSocketsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected