forked from mirror/OpenTTD
(svn r1106) -Add: [Network] Added master-server protocol and advertise to
master-server option. No GUI yet, and disabled by default (it still is WIP)
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "table/strings.h"
|
||||
#include "network_server.h"
|
||||
#include "network_udp.h"
|
||||
#include "console.h"
|
||||
#include "command.h"
|
||||
#include "gfx.h"
|
||||
@@ -1198,7 +1199,7 @@ void NetworkPopulateCompanyInfo(void)
|
||||
if (ci != NULL && ci->client_playas > 0 && ci->client_playas <= MAX_PLAYERS) {
|
||||
if (strlen(_network_player_info[ci->client_playas-1].players) != 0)
|
||||
strncat(_network_player_info[ci->client_playas-1].players, ", ", sizeof(_network_player_info[ci->client_playas-1].players));
|
||||
|
||||
|
||||
strncat(_network_player_info[ci->client_playas-1].players, client_name, sizeof(_network_player_info[ci->client_playas-1].players));
|
||||
}
|
||||
}
|
||||
@@ -1372,6 +1373,9 @@ void NetworkServer_Tick(void)
|
||||
last_sync_frame = _frame_counter;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* See if we need to advertise */
|
||||
NetworkUDPAdvertise();
|
||||
}
|
||||
|
||||
#endif /* ENABLE_NETWORK */
|
||||
|
Reference in New Issue
Block a user