notaz.gp2x.de
/
picodrive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ed4a219
)
Restore support for short GG cheats.
author
iLag
<ilagdoesntcheckthisemail@gmail.com>
Sun, 26 Mar 2017 02:35:36 +0000
(19:35 -0700)
committer
notaz
<notasas@gmail.com>
Fri, 13 Oct 2017 21:53:09 +0000
(
00:53
+0300)
pico/patch.c
patch
|
blob
|
blame
|
history
diff --git
a/pico/patch.c
b/pico/patch.c
index
0962616
..
7f5d594
100644
(file)
--- a/
pico/patch.c
+++ b/
pico/patch.c
@@
-174,7
+174,7
@@
void genie_decode_ms(const char *code, struct patch *result)
/* Correct the address */
result->addr = ((result->addr >> 4) | (result->addr << 12 & 0xF000)) ^ 0xF000;
/* Optional: 3 digits for comp */
- if (code[8]){
+ if (code[8]
=='-'
){
for(i=8;i<11;++i)
{
if (i==9) continue; /* 2nd character is ignored */
@@
-314,7
+314,7
@@
void decode(const char* code, struct patch* result)
//If Master System
//Genie
- if(len
== 11 && code[3] == '-' && code[7
] == '-')
+ if(len
>= 7 && code[3
] == '-')
{
genie_decode_ms(code, result);
}