Fixed net event data being dropped in packet-server mode

Previously hosts would clear this data after executing which cannot be done as this will fundamentally break retransmissions when playing in packet-server mode.
This commit is contained in:
Boondorl 2025-08-12 06:39:01 -04:00 committed by Ricardo Luís Vaz Silva
commit f2745e4c82
2 changed files with 4 additions and 8 deletions

View file

@ -2573,12 +2573,8 @@ void G_WriteDemoTiccmd (usercmd_t *cmd, int player, int buf)
// [RH] Write any special "ticcmds" for this player to the demo
if ((specdata = ClientStates[player].Tics[buf % BACKUPTICS].Data.GetData (&speclen)) && !(gametic % TicDup))
{
WriteBytes(TArrayView(specdata, speclen), demo_p);
ClientStates[player].Tics[buf % BACKUPTICS].Data.SetData(nullptr, 0);
}
// [RH] Now write out a "normal" ticcmd.
WriteUserCmdMessage (*cmd, &players[player].cmd, demo_p);