1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
|
/**NOTES//!
==
MY NOTES
==
*/
const char *FS_ReferencedPakPureChecksums( void ) {
static char info[BIG_INFO_STRING];
searchpath_t *search;
int numPaks, checksum;
info[0] = 0;
//! My Notes
// int z = 0;
// int y = 0;
// int firsttime;
checksum = fs_checksumFeed;
Com_DPrintf("\n\n\n\n\nchecksum feed is '%d'\n", fs_checksumFeed);
numPaks = 0; //My Notes
char checksum1[BIG_INFO_STRING];
char checksum2[BIG_INFO_STRING];
int times = 0;
for ( search = fs_searchpaths ; search; search = search->next )
{
if ( search->pack && strcmp(search->pack->pakGamename, "MN") )
{
if (times == 0)
{
strcpy(checksum1, va("%i ", search->pack->pure_checksum ));
Com_DPrintf("checksum1 coming from %s\n\n", search->pack->pakFilename);
checksum ^= search->pack->pure_checksum;
}
if (times == 1)
{
strcpy(checksum2, va("%i ", search->pack->pure_checksum ));
Com_DPrintf("checksum2 coming from %s\n\n", search->pack->pakFilename );
checksum ^= search->pack->pure_checksum;
}
times++;
}
else
{
if (search->pack)
Com_DPrintf("search->pack->Filename %s dropped\n", search->pack->pakFilename );
}
}
Com_DPrintf( "info %s\n", info );
strcat( info, checksum2 );
Com_DPrintf( "info %s\n", info );
strcat( info, checksum2 );
Com_DPrintf( "info %s\n", info );
info[strlen(info)+1] = '\0';
Com_DPrintf( "info %s\n", info );
info[strlen(info)+2] = '\0';
Com_DPrintf( "info %s\n", info );
info[strlen(info)] = '@';
Com_DPrintf( "info %s\n", info );
info[strlen(info)] = ' ';
Com_DPrintf( "info %s\n", info );
strcat( info, checksum1 );
Com_DPrintf( "info %s\n", info );
strcat( info, checksum2 );
Com_DPrintf( "info %s\n", info );
numPaks = 2;
// My Notes
checksum ^= numPaks;
Q_strcat( info, sizeof( info ), va("%i ", checksum ) );
Com_DPrintf("the string from client to server of pure packs is\n%s\n\n\n\n\n", info);
fflush(NULL);
return info;
}
|