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

Function MultiDoRequestBuildings

Descent3/multi.cpp:2429–2443  ·  view source on GitHub ↗

Tell a client about the buildings Server only

Source from the content-addressed store, hash-verified

2427// Tell a client about the buildings
2428// Server only
2429void MultiDoRequestBuildings(uint8_t *data) {
2430 int count = 0;
2431
2432 // Skip header stuff
2433 SKIP_HEADER(data, &count);
2434
2435 uint8_t slot = MultiGetByte(data, &count);
2436 if (!(NetPlayers[slot].flags & NPF_CONNECTED)) {
2437 mprintf(1, "ERROR! We got a request buildings packet from a disconnected player!\n");
2438 Int3(); // Get Jason
2439 return;
2440 }
2441
2442 NetPlayers[slot].sequence = NETSEQ_REQUEST_BUILDINGS;
2443}
2444
2445// Tell a client about the objects
2446// Server only

Callers 1

MultiProcessDataFunction · 0.85

Calls 2

SKIP_HEADERFunction · 0.85
MultiGetByteFunction · 0.85

Tested by

no test coverage detected