shonumi / gbe-plus

DMG/GBC/GBA emulator and experimental NDS emulator.
GNU General Public License v2.0
521 stars 79 forks source link

Cheats, Memory editor, Ascii editor, Hex editor, assembler, disassembler, memory hacks, memory dumping and restoring. #16

Open ADormant opened 8 years ago

ADormant commented 8 years ago

You are working on the debugger right now so I wonder if such features are feasible such editors would be very helpful for rom hacking and translating.

http://ngemu.com/threads/playstation-emulator-cheater-setup-guide.101186/ http://pec.duttke.de/ http://www.aldostools.org/pecedit.html https://github.com/strobejb/HexEdit https://github.com/evanmiller/hecate http://www.zophar.net/utilities/hexutil.html http://homepage.ntlworld.com/simon.mallion/PSXMemTool/

https://github.com/bryanperris/Soft64-Bryan/commit/a32c8417d654ad1f1b2d5d123a25d8c7bd876be3 https://github.com/bryanperris/Soft64-Bryan/commit/cbc5900fe9003bec3f505f798a350124b1f748ba https://github.com/bryanperris/Soft64-Bryan/commit/ae12be0b95193d1188353b234fda5e8d751ba073 https://github.com/bryanperris/Soft64-Bryan/commit/317792db0a60221a7275bbd7ebadc5b5ca24d056 https://github.com/bryanperris/Soft64-Bryan/commit/30bade4a1422f81909693bdeba9f5ab8e2958845 https://github.com/bryanperris/Soft64-Bryan/commit/983a2123ca0850c139daf38343341cbc3c5cb0e2 https://github.com/bryanperris/Soft64-Bryan/commit/73cccc85990ebd942cf233ae552a71d0d9d7cf79 https://github.com/bryanperris/Soft64-Bryan/commit/547f411fbfade98796db9e273680567db7a3e30c https://github.com/bryanperris/Soft64-Bryan/commit/fc87976f1f66a0377fd75f11868c552c4495920a https://github.com/bryanperris/Soft64-Bryan/commit/ef23217f69cba4bb7b89fcd202360432070ad00b https://github.com/bryanperris/Soft64-Bryan/commit/e395d0ebe2e3fed33583c135c96cd50f04c5edf7 https://github.com/bryanperris/Soft64-Bryan/commit/26912be38688650a24e82e0307204ea17fe6171a https://github.com/bryanperris/Soft64-Bryan/commit/e6e18d683c4dbacfee362435c9ccb4a7339c9124 https://github.com/bryanperris/Soft64-Bryan/commit/c1058582e1e3cbc2cf796c0ecb17373e921b1196 https://github.com/bryanperris/Soft64-Bryan/commit/5cd103903fe40c0e9ac9e913e899ad9daa63c50b https://github.com/bryanperris/Soft64-Bryan/commit/e90bbabb2fea1622f09051b0cc130340bc6c5c3e https://github.com/bryanperris/Soft64-Bryan/commit/6f11e13cff36d551390531e797f34e4296fe956b https://github.com/bryanperris/Soft64-Bryan/commit/9dd6eff6c5f7f06c5bbf472a06f74b02098f7cc1 https://github.com/bryanperris/Soft64-Bryan/commit/fdfa10b08f34798f357a76c3444083d6a991dcb7 https://github.com/bryanperris/Soft64-Bryan/commit/0f21f4a96e33d3b382ca3c3fbe622d72f6977ab3 https://github.com/bryanperris/Soft64-Bryan/commit/96b3b6328186353e9da4944428cfffe0db54debb https://github.com/bryanperris/Soft64-Bryan/commit/824c96abd61561cea4d84e71460d1a01609150a6

shonumi commented 8 years ago

It's possible once the debugger is finished, though it'd be pretty low-priority.

shonumi commented 8 years ago

Marking it as an enhancement for now (it's basically going to be the RAM tab, but instead of just viewing data, it will let you view and edit data).

GregoryMcGregerson commented 8 years ago

I like the idea of having an editor. Some levels can be changed in certain games with some simple HEX edits. And having cheats will be helpful to get to certain areas quickly to check on tile replacement.

shonumi commented 8 years ago

Shouldn't be too hard to implement. I'm working on the memory viewer tonight. Hopefully Qt will make this quick. Fwiw, I'm no stranger to hex editors (a hex editor was my first solo FOSS project). I'll update you guys as progress is made ;)

ADormant commented 8 years ago

@shonumi Will it have the option to dump and reload memory for memory hacks like the one in that PEC PSX plugin? Dolphin and PPSSPP have memory editors also https://github.com/devinacker/bsnes-plus , VBA-M and FXEUX which has hex editor too. http://www.fceux.com/web/help/fceux.html?MemoryWatch.html http://www.fceux.com/web/help/fceux.html?HexEditor.html , https://sourceforge.net/projects/fceultra/ , http://www.fceux.com/web/help/fceux.html?PPUViewer.html Desmume http://wiki.desmume.org/index.php?title=DeSmuME_Manual_for_the_Windows_port#Tools_.7C_View_Memory , https://forums.dolphin-emu.org/Thread-howto-cheating-in-games https://www.youtube.com/watch?v=F_wu7Mh8v24 http://www.fceux.com/web/help/fceux.html?RAMWatch.html http://www.fceux.com/web/help/fceux.html?MemoryWatch.html http://www.fceux.com/web/help/fceux.html?NameTableViewer.html http://www.fceux.com/web/help/fceux.html?TraceLogger.html http://www.fceux.com/web/help/fceux.html?Debugger.html http://www.fceux.com/web/help/fceux.html?HexEditor.html http://www.fceux.com/web/help/fceux.html?RAMSearch.html http://www.fceux.com/web/help/fceux.html?PPUViewer.html

shonumi commented 8 years ago

Yes, memory dumping/loading is trivial.

Fwiw, you don't have to always post handfuls of links. I have a very solid idea on how this is going to work ;)

ADormant commented 8 years ago

Great we have ascii and hex values now thanks. I don't know if that's not too much to ask but would it be doable to add some additional values to the debugger like EBCDIC, Unicode, Shift-JIS , EUC-JP , binary, signed, decimal , float and double? Different roms/games require different approaches.

shonumi commented 8 years ago

Yes, that's all a bit too much :P

If someone wants to get that involved, it's best to dump the memory and edit it in a proper hex editor.

EDIT: Also, as you can see with the latest commit, the memory viewer is a bit rough in terms of proper text formating. Going to spend the weekend fixing it up in Qt.

ADormant commented 8 years ago

The most useful would be EBCDIC, Unicode, Shift-JIS and EUC-JP because Japanese games use these formats for text and they are hard to modify with just hex editors. Perhaps a converter from these formats to hex is possible but I guess it's hard.

shonumi commented 8 years ago

Something like http://www.wxhexeditor.org/ already handles those encodings fairly well though. Trying to implement a full-featured hex editor into GBE+ seems like feature creep to me. I'm going to keep it simple and straightforward. If the user has more advanced needs, they should turn to advanced programs dedicated for hex editing (wxHexEditor is really, really nice too). GBE+'s editor should be minimal, "quick and dirty", but gets most jobs done.

ADormant commented 8 years ago

https://github.com/bryanperris/Soft64-Bryan/commit/cb1dd2c13b83e1e3758bd74ee599bda2d2b66b3a https://github.com/bryanperris/Soft64-Bryan/commit/04cedaac2b2d7c819ff35560f0864ea1d73883dc https://github.com/bryanperris/Soft64-Bryan/commit/e084ad0a1757e39ee5041443e58f9b216e383a81 https://github.com/bryanperris/Soft64-Bryan/commit/8235acdea292c414d8d0224c6dcce5117902a1b9 https://github.com/bryanperris/Soft64-Bryan/commit/a7b75add944e46814d7a32a4d94e7ca8fc906e31 https://github.com/bryanperris/Soft64-Bryan/commit/cc91f438772bc16a465cfed323372bbf1306ba5f

ADormant commented 8 years ago

Does debuggers support memory breakpoints?

shonumi commented 8 years ago

Not yet. The CLI debugger does. The core needs a way to expose CPU registers to the GUI. It's coming in the next few days, so keep your eyes open. Can't add everything at once after all :P