GBA: Silence some warnings in cheats

This commit is contained in:
Jeffrey Pfau 2015-02-20 23:59:12 -08:00
parent 486a0e4017
commit 86ff4b1577
1 changed files with 6 additions and 3 deletions

View File

@ -175,6 +175,7 @@ static const char* _hex32(const char* line, uint32_t* out) {
static const char* _hex16(const char* line, uint16_t* out) { static const char* _hex16(const char* line, uint16_t* out) {
uint16_t value = 0; uint16_t value = 0;
*out = 0;
int i; int i;
for (i = 0; i < 4; ++i, ++line) { for (i = 0; i < 4; ++i, ++line) {
char digit = *line; char digit = *line;
@ -330,11 +331,13 @@ static bool _addGSA1(struct GBACheatSet* cheats, uint32_t op1, uint32_t op2) {
return true; return true;
} }
static bool _addGSA3(struct GBACheatSet* cheats, uint32_t op1, uint32_t op2) { static bool _addPAR3(struct GBACheatSet* cheats, uint32_t op1, uint32_t op2) {
// TODO // TODO
UNUSED(cheats); UNUSED(cheats);
UNUSED(op1); UNUSED(op1);
UNUSED(op2); UNUSED(op2);
UNUSED(_par3T1);
UNUSED(_par3T2);
return false; return false;
} }
@ -659,7 +662,7 @@ bool GBACheatAddAutodetect(struct GBACheatSet* set, uint32_t op1, uint32_t op2)
_decryptGameShark(&o1, &o2, _par3S); _decryptGameShark(&o1, &o2, _par3S);
if ((o1 & 0xFE000000) == 0xC4000000 && !(o2 & 0xFFFF0000)) { if ((o1 & 0xFE000000) == 0xC4000000 && !(o2 & 0xFFFF0000)) {
_setGameSharkVersion(set, 3); _setGameSharkVersion(set, 3);
return _addGSA3(set, o1, o2); return _addPAR3(set, o1, o2);
} }
break; break;
case 1: case 1:
@ -667,7 +670,7 @@ bool GBACheatAddAutodetect(struct GBACheatSet* set, uint32_t op1, uint32_t op2)
return _addGSA1(set, o1, o2); return _addGSA1(set, o1, o2);
case 3: case 3:
_decryptGameShark(&o1, &o2, set->gsaSeeds); _decryptGameShark(&o1, &o2, set->gsaSeeds);
return _addGSA3(set, o1, o2); return _addPAR3(set, o1, o2);
} }
return false; return false;
} }