Got_AddBot: build party and set playerconsole

Fixes bot's local party being empty (fails assert at
G_LeaveParty).
This commit is contained in:
James R 2023-05-18 18:40:00 -07:00
parent cf120e7d8e
commit 11b2ee0d26

View file

@ -4038,6 +4038,9 @@ static void Got_AddBot(UINT8 **p, INT32 playernum)
sprintf(player_names[newplayernum], "%s", skins[skinnum].realname);
SetPlayerSkinByNum(newplayernum, skinnum);
playerconsole[newplayernum] = newplayernum;
G_BuildLocalSplitscreenParty(newplayernum);
if (netgame)
{
HU_AddChatText(va("\x82*Bot %d has been added to the game", newplayernum+1), false);
@ -7108,4 +7111,4 @@ void SendServerNotice(SINT8 target, char *message)
if (client)
return;
DoSayCommand(message, target + 1, HU_PRIVNOTICE, servernode);
}
}