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

Function MultiAddObjAnimUpdate

Descent3/multi.cpp:6873–6898  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6871}
6872
6873void MultiAddObjAnimUpdate(int objnum) {
6874 MULTI_ASSERT_NOMESSAGE(Netgame.local_role == LR_SERVER);
6875 ASSERT(Objects[objnum].flags & OF_CLIENT_KNOWS);
6876 // mprintf(0,"D`");
6877 for (int i = 0; i < MAX_NET_PLAYERS; i++) {
6878 if (i == Player_num)
6879 continue;
6880 bool skip_this_obj = false;
6881 if ((NetPlayers[i].flags & NPF_CONNECTED) && (NetPlayers[i].sequence == NETSEQ_PLAYING)) {
6882 skip_this_obj = false;
6883 // Check to see if this robot is on the list already
6884 for (int b = 0; b < Num_changed_anim[i]; b++) {
6885 if (Changed_anim[b][i] == Objects[objnum].handle) {
6886 skip_this_obj = true;
6887 break;
6888 }
6889 }
6890 if (skip_this_obj == false) {
6891 if (Num_changed_anim[i] < MAX_CHANGED_OBJECTS) {
6892 Changed_anim[Num_changed_anim[i]][i] = Objects[objnum].handle;
6893 Num_changed_anim[i]++;
6894 }
6895 }
6896 }
6897 }
6898}
6899
6900int MultiStuffObjAnimUpdate(uint16_t objnum, uint8_t *data) {
6901 custom_anim multi_anim_info;

Callers 1

AIUpdateAnimFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected