From 83f8bd40af68bd0e161b93704408b76e904039b8 Mon Sep 17 00:00:00 2001 From: Pixel Date: Tue, 16 Jul 2002 10:35:56 +0000 Subject: VePeeeeeeeeee --- Xenogears/Decrypt.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'Xenogears') diff --git a/Xenogears/Decrypt.cpp b/Xenogears/Decrypt.cpp index 2f4d99f..76289e2 100644 --- a/Xenogears/Decrypt.cpp +++ b/Xenogears/Decrypt.cpp @@ -52,14 +52,11 @@ void dump_text(FILE * f_source, FILE * f_cible, long table[5000], long script_nu { long next; unsigned char val; - char temp_string[2]; + char temp_string[2] = {0, 0}; long position; unsigned char temp1 = 0; unsigned char temp2 = 0; - long temp; - - temp_string[1] = NULL; - + next = found_next(table, script_number, max_script); fseek(f_source, table[script_number], SEEK_SET); @@ -86,7 +83,7 @@ void dump_text(FILE * f_source, FILE * f_cible, long table[5000], long script_nu } else if (val == 0x03) // "" { fprintf(f_cible, ""); - } else if (val == 0x0F) // " + } else if (val == 0x0F) // Extended opcode. Reads two more bytes. { fread((unsigned char *) &temp1, 1, 1, f_source); fread((unsigned char *) &temp2, 1, 1, f_source); @@ -435,7 +432,7 @@ int decrypt(FILE * f_source, FILE * f_cible, int room_number) script_number = (script_number++); - fprintf(f_cible, "\n", script_number); + fprintf(f_cible, "\n", script_number); init_table(table); i = j = 0; -- cgit v1.2.3