Hacking M3 Perfect saves to readable by 3in1

4saken

Retired Ace Attorney
OP
Member
Joined
Nov 28, 2006
Messages
3,357
Trophies
0
Website
Visit site
XP
145
Country
I'm changing all my gear in the near future: getting a GBM and EZ4, and a 3in1 for my DS. I have a few questions I'm sure somebody can answer
smile.gif


1. How do I convert M3 Perfect GBA saves (.dat) to saves that are readable by Rudolphs 3in1 Tool? Also how do I convert these to saves readable by an EZ4.

2. I hear that games need to be patched to run (just like M3 if you want saves/features). For the 3in1, it is necessary to patch games which require some kind of save type - but is it necessary to patch all games? If some games need to be patched, while some others do not, there are no disadvantages of just patching every single game in case right?

Thats all for now
smile.gif
Thanks
 

Destructobot

Crave the Hammer
Member
Joined
Oct 15, 2006
Messages
5,002
Trophies
0
Age
45
Location
Portland, OR
Website
Visit site
XP
321
Country
United States
GBA games that use EEPROM and flash saves need to be patched to save on the 3-in-1 (and presumably the EZ-4, as the 3-in-1 is basically a stripped down version of the EZ-4.). Games that use SRAM saves do not need to be patched. You can run every rom through the EZ4 Client, it won't break anything.

As for converting saves, I don't know what format the M3 Perfect uses for GBA saves. If you post a save (or preferably saves from multiple games with different save types) from the M3 I could check it out and see what needs to happen to convert the saves.
 
P

pasc

Guest
Ok, Destructobot,

I guess I'll get a 3 in 1 too, but I first off want to know if these saves will work. I uploaded them here .
I know that saves like Max Payne and Payback make problems when converting them to raw .sav files, so you may want to look into them specifically.

I also included a Mario Tennis.dat and a Mario Tennis.sav I converted using Thulinmas Save Tool, I know that that saves works on the Ez 3-in-1 because I had someone to test it for me (thx FoxMcCloud ^^).

I hope you could take a look and fiddel around with the saves a a bit.

Thx in advance:

pasc
 

Destructobot

Crave the Hammer
Member
Joined
Oct 15, 2006
Messages
5,002
Trophies
0
Age
45
Location
Portland, OR
Website
Visit site
XP
321
Country
United States
I've had a look at the M3 saves, and most of them can be converted easily. For games that use SRAM and Flash save types, you just trim the file to 128KB and rename it to .SAV, and you have the same save format that the 3in1 Expansion Pack Tool uses. I use File Trimmer for this, but a hex editor would work as well.

EEPROM saves are more difficult to convert, but still possible. The save data doesn't start at the beginning of the file like it does with Flash or SRAM saves, instead it's offset 16KB into the file. Furthermore, the order of every 8 byte chunk of data is reversed in EEPROM saves (e.g. 12345678 90ABCDEF is stored as 87654321 FEDCBA09). VBA and the 3-in-1 store the data with the bytes flipped, but the M3 does not, so that has to be corrected before the saves can be used.

Hex Workshop has an option to flip the byte order (Tools -> Operations -> Byte Flip... -> Treat Data As: 64 Bit Unsigned Quad -> OK), some other hex editors probably have that option too, but I don't know which ones specifically. There is also a Perl script that will do this; you can get it here: http://wiki.pocketheaven.com/FlashManager

I trimmed the first 16KB from the Max Payne and Payback saves so that the save data was at the start of the file, trimmed them down to 512 bytes (the size of the save data; EEPROM saves are either 512 bytes or 8KB), byte flipped them in Hex Workshop, and ran them through my save padding script to get the standard 128KB file size. The resulting files seem to work properly on the 3-in-1 with the 3in1 Expansion Pack Tool.

Here are the converted Max Payne & Payback saves: http://www.zshare.net/download/6755926accb6ea/
 
P

pasc

Guest
thx ! I'll try them out as soon as myy Ez 3 in 1 arrives.

BTW: I tried that tool and had FoxMc Cloud testing the Saves for me and they worked all !

Let's hope all works out well in the end.

EDIT:

Well, my EZ 3 in 1 arrived today, and I tried you saves (I SRAM patched the games with the EZ Client).

Payback kinda works (except that it tells me that I finishedthe game with gold and had 0 incidents since them, which for sure isn't all right, but better than nothing)

and Max Payne doesn't work at all.

I also got 3 other saves which won't work no matter what... I tried Thulinmas Save tool, the Save Tool which "should" work with EZ 3 in 1 Savs and of course the file trimmer you suggested, but nothing helped
unsure.gif
.

They won't load no matter what. If you care, here they are.

BTW: I think it quite bothers you that I do write my whole stuff in here, so I want to ask you (cause I saw you already did a similar save padding/converting tool) if you could do something similar for

M3 Saves to Ez 3 in 1

Thanks for your time once again


EDIT:

I found out something VERY interesting:

The saves that don't work with the Ez 3 in 1 don't work with Visual Boy Advance either, but the ones that work for the Ez 3 in 1 strange enough WORKS WITH VBA

So if there would be a way to make them work with VBA...
 

Destructobot

Crave the Hammer
Member
Joined
Oct 15, 2006
Messages
5,002
Trophies
0
Age
45
Location
Portland, OR
Website
Visit site
XP
321
Country
United States
It looks like .dat saves from games that use EEPROM 64kbit save types have the save data offset 24KB into the file, instead of 16KB like saves from games that use EEPROM 4kbit saves. Aside from that, the conversion process is the same.

Try these saves: http://mihd.net/ert7c3

QUOTE said:
The saves that don't work with the Ez 3 in 1 don't work with Visual Boy Advance either, but the ones that work for the Ez 3 in 1 strange enough WORKS WITH VBA
VBA, like nearly every flashcart other than the M3 Perfect, uses raw save files. The only difference between the saves created by VBA and the ones created by the 3in1 Expansion Pack Tool is the file size; the 3in1 Expansion Pack Tool pads every save file to 128KB, VBA does not. Save files are interchangeable between VBA and the 3in1 Expansion Pack Tool.
 
P

pasc

Guest
Wow thx Destructobot thats awesome ! They all work like a charm !

Any way to build bats that will convert from dat to 4k eeprom and 64 ? I mean so you don't have to do this incase someone else wants them.
 

Destructobot

Crave the Hammer
Member
Joined
Oct 15, 2006
Messages
5,002
Trophies
0
Age
45
Location
Portland, OR
Website
Visit site
XP
321
Country
United States
No. Padding and renaming files is easy with batch scripts; this sort of conversion is much more complicated.

If I had a command line file trimmer and a command line byte flipper I could write a batch file that would use them to convert these saves, but I don't know of any such programs. Even if I did, I don't know of any way to tell from the .dat file which save type the game uses, so it would require three different batch files, and you would have to figure out what save type the game used before you could convert the save.
 
P

pasc

Guest
QUOTE said:
so it would require three different batch files, and you would have to figure out what save type the game used before you could convert the save

That'd be enough ! It would be the way to go ! Why don't you ask around in gbadev.org if someone might get you a command line file trimmer and a command line byte flipper ? They usually have the knoweldge to build/find this kind of stuff.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    rvtr @ rvtr: Spam bots again.