- // an update has been successfully written
- client->csqcentitysendflags[number] = 0;
- // and take note that we have begun the svc_csqcentities
- // section of the packet
- sectionstarted = 1;
- if (msg->cursize + 17 >= maxsize)
- break;
- ENTITYSIZEPROFILING_END(msg, number);
- continue;
+ ENTITYSIZEPROFILING_START(msg, number);
+ MSG_WriteShort(msg, number);
+ msg->allowoverflow = true;
+ PRVM_G_INT(OFS_PARM0) = sv.writeentitiestoclient_cliententitynumber;
+ PRVM_G_FLOAT(OFS_PARM1) = sendflags;
+ prog->globals.server->self = number;
+ PRVM_ExecuteProgram(val->function, "Null SendEntity\n");
+ msg->allowoverflow = false;
+ if(PRVM_G_FLOAT(OFS_RETURN) && msg->cursize + 2 <= maxsize)
+ {
+ // an update has been successfully written
+ client->csqcentitysendflags[number] = 0;
+ // and take note that we have begun the svc_csqcentities
+ // section of the packet
+ sectionstarted = 1;
+ if (msg->cursize + 17 >= maxsize)
+ break;
+ ENTITYSIZEPROFILING_END(msg, number);
+ continue;
+ }