mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 07:17:45 -04:00
made SMD detection less likely to take .bin files
git-svn-id: file:///home/notaz/opt/svn/PicoDrive@477 be3aeb3a-fb24-0410-a615-afba39da0efa
This commit is contained in:
parent
760e26c7dd
commit
21395e3878
1 changed files with 4 additions and 1 deletions
|
@ -481,7 +481,10 @@ int PicoCartLoad(pm_file *f,unsigned char **prom,unsigned int *psize)
|
|||
}
|
||||
|
||||
// Check for SMD:
|
||||
if ((size&0x3fff)==0x200) { DecodeSmd(rom,size); size-=0x200; } // Decode and byteswap SMD
|
||||
if (size >= 0x4200 && (size&0x3fff)==0x200 &&
|
||||
((rom[0x2280] == 'S' && rom[0x280] == 'E') || (rom[0x280] == 'S' && rom[0x2281] == 'E'))) {
|
||||
DecodeSmd(rom,size); size-=0x200; // Decode and byteswap SMD
|
||||
}
|
||||
else Byteswap(rom,size); // Just byteswap
|
||||
|
||||
if (prom) *prom=rom;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue