DirectorInfo::update_positions: fix player index out of bounds if all players are spectating

This commit is contained in:
James R 2024-02-03 01:47:08 -08:00
parent efd0170856
commit 057001a66f

View file

@ -212,6 +212,12 @@ private:
}
}
if (playerstat[0].sorted == -1)
{
maxdist = -1;
return;
}
maxdist = P_ScaleFromMap(players[playerstat[0].sorted].distancetofinish, FRACUNIT);
}