forked from cafeberry/cafeberry
LCEMP commit: support more max players
This commit is contained in:
@@ -1309,7 +1309,7 @@ void NetworkSocketLayer::UpdateAdvertisePlayerNames(BYTE count, const char playe
|
||||
EnterCriticalSection(&s_advertiseLock);
|
||||
memset(s_advertiseData.playerNames, 0, sizeof(s_advertiseData.playerNames));
|
||||
s_advertiseData.playerCount = count;
|
||||
for (int i = 0; i < count && i < 8; i++)
|
||||
for (int i = 0; i < count && i < NETWORK_LAN_BROADCAST_PLAYERS; i++)
|
||||
{
|
||||
memcpy(s_advertiseData.playerNames[i], playerNames[i],
|
||||
NETWORK_LAN_PLAYER_NAME_SIZE < (int)XUSER_NAME_SIZE ? NETWORK_LAN_PLAYER_NAME_SIZE : (int)XUSER_NAME_SIZE);
|
||||
@@ -1587,7 +1587,7 @@ int NetworkSocketLayer::DiscoveryThreadProc(LPVOID param)
|
||||
|
||||
broadcast->hostName[31] = L'\0';
|
||||
|
||||
for (int pn = 0; pn < 8; pn++)
|
||||
for (int pn = 0; pn < NETWORK_LAN_BROADCAST_PLAYERS; pn++)
|
||||
broadcast->playerNames[pn][XUSER_NAME_SIZE - 1] = '\0';
|
||||
|
||||
char senderIP[64];
|
||||
|
||||
Reference in New Issue
Block a user