Merge branch 'fix-director-splitscreen' into 'master'

Director: skip splitscreen players when switching

See merge request KartKrew/Kart!986
This commit is contained in:
Oni 2023-02-28 05:10:22 +00:00
commit ce4ab6c5a8

View file

@ -285,8 +285,20 @@ void K_UpdateDirector(void)
target = directorinfo.sortedplayers[targetposition];
// stop here since we're already viewing this player
if (*displayplayerp == target)
{
break;
}
// if this is a splitscreen player, try next pair
if (P_IsDisplayPlayer(&players[target]))
{
continue;
}
// if we're certain the back half of the pair is actually in this position, try to switch
if (*displayplayerp != target && !players[target].positiondelay)
if (!players[target].positiondelay)
{
K_DirectorSwitch(target, false);
}