fixed: players could not rejoin. addr->plnr needed to be deleted in an if () part.

origin
stpohle 22 years ago
parent 33dc3a7a6e
commit b8a015b121

@ -100,7 +100,7 @@ do_joingame (struct pkg_joingame *p_jg, _net_addr * addr) {
} }
/* find a free place for the player and add the player to the game*/ /* find a free place for the player and add the player to the game*/
if ((addr->pl_nr == -1) && GS_WAITRUNNING && GT_MP_PTPM) { if (GS_WAITRUNNING && GT_MP_PTPM) {
/* find free player slot */ /* find free player slot */
if (addr->pl_nr == -1) if (addr->pl_nr == -1)
for (i = 0; (i < MAX_PLAYERS && PS_IS_used (players[i].state)); i++); for (i = 0; (i < MAX_PLAYERS && PS_IS_used (players[i].state)); i++);
@ -138,8 +138,8 @@ do_joingame (struct pkg_joingame *p_jg, _net_addr * addr) {
bman.players_nr_s++; bman.players_nr_s++;
/* send to the new client the servermode and the complete playerlist */ /* send to the new client the servermode and the complete playerlist */
send_servermode (addr, i);
send_mapinfo (addr); send_mapinfo (addr);
send_servermode (addr, i);
addr->pl_nr = i; addr->pl_nr = i;

Loading…
Cancel
Save