Fix assert when entering splitscreen on replays (closes #94)

The problem is quite simple: G_LeaveParty is called for the old value of
displayplayers[1] which is 0, and this triggers the assert for replays from
dedi servers where player 0 doesn't exist.
No idea if the fix is correct but I assume making a non-existent player
leave their party is nonsense
This commit is contained in:
GenericHeroGuy 2025-09-27 19:16:02 +02:00
parent 28c4ebd968
commit 0cffa16a45

View file

@ -4485,7 +4485,8 @@ void G_SyncDemoParty(INT32 rem, INT32 newsplitscreen)
// viewports.
// Remove this player
G_LeaveParty(rem);
if (playeringame[rem])
G_LeaveParty(rem);
// And reset the rest of the party
for (int i = 0; i <= r_splitscreen_copy; ++i)