do_quit from a server will make sure that the new server will have control

of the ai players, PSF_net will be deleted by all AI players.
origin
stpohle 21 years ago
parent 6e774bdc18
commit 4486b04a4d

@ -1033,8 +1033,16 @@ do_quit (struct pkg_quit *q_dat, _net_addr * addr)
d_printf ("do_quit: new server is set to: %d\n", q_dat->new_server); d_printf ("do_quit: new server is set to: %d\n", q_dat->new_server);
bman.p_servnr = q_dat->new_server; bman.p_servnr = q_dat->new_server;
if (GT_MP_PTPM && bman.notifygamemaster) if (GT_MP_PTPM && bman.notifygamemaster) {
/* if there are any AI players delete the network flag from them */
int i;
for (i = 0; i < MAX_PLAYERS; i++)
if (PS_IS_aiplayer (players[i].state))
players[i].state &= (0xFF - PSF_net);
send_ogc_update (); send_ogc_update ();
}
} }
bman.updatestatusbar=1; bman.updatestatusbar=1;

Loading…
Cancel
Save