mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2025-01-13 21:31:32 +00:00
Merge branch 'playerinfo_mscompat' into 'master'
Fix compatibility with the MS (Specifically Doomseeker) See merge request KartKrew/Kart-Public!142
This commit is contained in:
commit
987b20e5b6
3 changed files with 12 additions and 3 deletions
|
@ -1428,8 +1428,14 @@ static void SV_SendPlayerInfo(INT32 node)
|
|||
UINT8 i;
|
||||
netbuffer->packettype = PT_PLAYERINFO;
|
||||
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
for (i = 0; i < MSCOMPAT_MAXPLAYERS; i++)
|
||||
{
|
||||
if (i >= MAXPLAYERS)
|
||||
{
|
||||
netbuffer->u.playerinfo[i].node = 255;
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!playeringame[i])
|
||||
{
|
||||
netbuffer->u.playerinfo[i].node = 255; // This slot is empty.
|
||||
|
@ -1477,7 +1483,7 @@ static void SV_SendPlayerInfo(INT32 node)
|
|||
netbuffer->u.playerinfo[i].data |= 0x80;
|
||||
}
|
||||
|
||||
HSendPacket(node, false, 0, sizeof(plrinfo) * MAXPLAYERS);
|
||||
HSendPacket(node, false, 0, sizeof(plrinfo) * MSCOMPAT_MAXPLAYERS);
|
||||
}
|
||||
|
||||
/** Sends a PT_SERVERCFG packet
|
||||
|
|
|
@ -468,7 +468,7 @@ typedef struct
|
|||
serverrefuse_pak serverrefuse; // 65025 bytes (somehow I feel like those values are garbage...)
|
||||
askinfo_pak askinfo; // 61 bytes
|
||||
msaskinfo_pak msaskinfo; // 22 bytes
|
||||
plrinfo playerinfo[MAXPLAYERS]; // 576 bytes(?)
|
||||
plrinfo playerinfo[MSCOMPAT_MAXPLAYERS];// 576 bytes(?)
|
||||
plrconfig playerconfig[MAXPLAYERS]; // (up to) 528 bytes(?)
|
||||
INT32 filesneedednum; // 4 bytes
|
||||
filesneededconfig_pak filesneededcfg; // ??? bytes
|
||||
|
|
|
@ -252,6 +252,9 @@ extern FILE *logstream;
|
|||
#define PLAYERSMASK (MAXPLAYERS-1)
|
||||
#define MAXPLAYERNAME 21
|
||||
|
||||
// Master Server compatibility ONLY
|
||||
#define MSCOMPAT_MAXPLAYERS (32)
|
||||
|
||||
typedef enum
|
||||
{
|
||||
SKINCOLOR_NONE = 0,
|
||||
|
|
Loading…
Reference in a new issue