Cleanup and fixes
This commit is contained in:
parent
d9eade8944
commit
aa0f5b153e
1 changed files with 3 additions and 3 deletions
|
@ -108,7 +108,7 @@ int main(int argc, char *argv[])
|
||||||
const int decode_table[6] = {0, 1, 2, 4, 5, 3};
|
const int decode_table[6] = {0, 1, 2, 4, 5, 3};
|
||||||
|
|
||||||
fseek(file, 3, SEEK_CUR);
|
fseek(file, 3, SEEK_CUR);
|
||||||
configuration.joystick_button[i] = decode_table[fgetc(file)];
|
configuration.joystick_button[i] = decode_table[fgetc(file) - 1];
|
||||||
}
|
}
|
||||||
|
|
||||||
fclose(file);
|
fclose(file);
|
||||||
|
@ -247,7 +247,7 @@ int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
const int encode_table[6] = {0, 1, 2, 5, 3, 4};
|
const int encode_table[6] = {0, 1, 2, 5, 3, 4};
|
||||||
|
|
||||||
fputc(encode_table[configuration.joystick_button[i]], file);
|
fputc(encode_table[configuration.joystick_button[i]] + 1, file);
|
||||||
fputc(0, file);
|
fputc(0, file);
|
||||||
fputc(0, file);
|
fputc(0, file);
|
||||||
fputc(0, file);
|
fputc(0, file);
|
||||||
|
|
Loading…
Add table
Reference in a new issue