Tech City in RESEARCH LIST


#define MAX_BUF_SIZE (10*1024)

main(int x, char **argv)

{

int a,t,c, x=0; FILE *fsave, *fback; unsigned char gamebuf[MAX_BUF_SIZE];

unsigned char fn_save[MAX_BUF_SIZE]; unsigned char fn_back[MAX_BUF_SIZE];



#define BLOCK_SIZE 0x16

#define off_ENABLE_RESEARCH 8



#define FN_SAVE "\\research.dat"

define FN_BACK "\\research.da_"



if (x<2)return printf("USAGE: ufo1-2AlienContainmentBugFix.exe path_to_save\n"\

"example: ufo1-2AlienContainmentBugFix.exe GAME_1\n");



printf("* * * ENABLING Cydonia or L' Tech City in RESEARCH LIST * * *\n");



strcpy(fn_save, argv[1]); strcat(fn_save, FN_SAVE);

strcpy(fn_back, argv[1]); strcat(fn_back, FN_BACK);



//

fsave = fopen(fn_save,"rb"); c = fread(gamebuf, 1, MAX_BUF_SIZE, fsave);

fback = fopen(fn_back, "wb");fwrite(gamebuf,1,c, fback);



// Cydonia/L'Tech



for (a = 0; a < c; a += BLOCK_SIZE) gamebuf[a + off_ENABLE_RESEARCH] = 1;



//

fclose(fsave); fsave = fopen(fn_save,"wb"); fwrite(gamebuf, 1, c, fsave);



printf("============================================================\n"\

"now see BASES > RESEARCH > Add New Project > Cydonia/L'Tech\n");

}

 17 , Cydonia/L'Tech UFO-2