cvar_t cl_anglespeedkey = {CVAR_SAVE, "cl_anglespeedkey","1.5"};
+cvar_t cl_nodelta = {0, "cl_nodelta", "0"};
/*
================
upmove += cmd->upmove;
total++;
// LordHavoc: cap outgoing movement messages to sys_ticrate
- if ((cl.maxclients > 1) && (realtime - lastmovetime < sys_ticrate.value))
+ if (!cl.islocalgame && (realtime - lastmovetime < sys_ticrate.value))
return;
lastmovetime = realtime;
// average what has happened during this time
MSG_WriteFloat (&buf, cl.mtime[0]); // so server can get ping times
- if (dpprotocol == DPPROTOCOL_VERSION2 || dpprotocol == DPPROTOCOL_VERSION3)
+ if (cl.protocol == PROTOCOL_DARKPLACES2 || cl.protocol == PROTOCOL_DARKPLACES3)
{
for (i = 0;i < 3;i++)
MSG_WriteFloat (&buf, cl.viewangles[i]);
}
- else if (dpprotocol == DPPROTOCOL_VERSION1)
+ else if (cl.protocol == PROTOCOL_DARKPLACES1 || cl.protocol == PROTOCOL_DARKPLACES4)
{
for (i=0 ; i<3 ; i++)
MSG_WritePreciseAngle (&buf, cl.viewangles[i]);
MSG_WriteByte (&buf, in_impulse);
in_impulse = 0;
- // LordHavoc: should we ack this on receipt instead? would waste net bandwidth though
- i = EntityFrame_MostRecentlyRecievedFrameNum(&cl.entitydatabase);
- if (i > 0)
+ if (cl.protocol == PROTOCOL_DARKPLACES1 || cl.protocol == PROTOCOL_DARKPLACES2 || cl.protocol == PROTOCOL_DARKPLACES3)
{
- MSG_WriteByte(&buf, clc_ackentities);
- MSG_WriteLong(&buf, i);
+ // LordHavoc: should we ack this on receipt instead? would waste net bandwidth though
+ i = EntityFrame_MostRecentlyRecievedFrameNum(&cl.entitydatabase);
+ if (i > 0)
+ {
+ MSG_WriteByte(&buf, clc_ackentities);
+ MSG_WriteLong(&buf, i);
+ }
+ }
+ else
+ {
+ if (cl.entitydatabase4)
+ {
+ i = cl.entitydatabase4->ackframenum;
+ if (cl_nodelta.integer)
+ i = -1;
+ if (developer_networkentities.integer)
+ Con_Printf("send clc_ackentities %i\n", i);
+ MSG_WriteByte(&buf, clc_ackentities);
+ MSG_WriteLong(&buf, i);
+ }
}
// deliver the message
Cmd_AddCommand ("-button7", IN_Button7Up);
Cmd_AddCommand ("+button8", IN_Button8Down);
Cmd_AddCommand ("-button8", IN_Button8Up);
+
+ Cvar_RegisterVariable(&cl_nodelta);
}