On 2012-09-19 17:23:24 +0000, Bob Tanner said:

>   SP_YOU, indicates slot number assigned

Just want to double check some things.

On osx (10.8) the "struct you_spacket" is 48 bytes.

struct you_spacket
{
    char    type;                                /* SP_YOU */
    char    pnum;                                /* Guy needs to know this...
    char    hostile;
    char    swar;
    char    armies;
    char    tractor;
    char    pad2;
    char    pad3;
    unsigned flags;
    LONG    damage;
    LONG    shield;
    LONG    fuel;
    unsigned short etemp;
    unsigned short wtemp;
    unsigned short whydead;
    unsigned short whodead;
};

Packet dump after the MOTD stuff looks like this for me.

0c100000 00000000 08000000 00000000 00000000 00000000 00000000 00000000 
18000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 
00000000 00000000 00000000 00000000 00000000 16000000 02000000 03000000 
00000000 14000000 12000000 00000000 04000000 00000000 00000000 18010000 
00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 
00000000 00000000 00000000 00000000 16010000 02010000 03010000 00000000 
14010000 12010000 00000000

Byte 0x0c (12) is SP_YOU

#define SP_YOU          12                       /* info on you? */

The next 48 bytes should fill in the "struct you_spacket" but that 
leaves 2 nybles of null bytes before the byte 0x18 (24) SP_PL_LOGIN is 
seen

#define SP_PL_LOGIN     24                       /* new player logs in */

In my code I replaced the (I assume) autoconf figured out LONG with 
long is that right?

I'd look at MacTrek but that's a 32-bit project and I'm attempting to 
write my stuff as a 64-bit project.

Why I'm confused is the MacTrek project has the SP_YOU structure at 32 
bytes, which would even leave more null bytes.

Just trying to figure out why I'm ending up 2 nybles short.

Thanks.

-- 
Bob Tanner <basic at us.netrek.org>          
Key fingerprint = 9906 320A 8BB6 64AD 96A7  7785 CBFB 10BF 568B F98C