Hacking Homebrew Patching Toadstool Tour PAL with an updated widescreen hack for Devolution

N7Kopper

Lest we forget... what Nazi stood for.
OP
Member
Joined
Aug 24, 2014
Messages
1,123
Trophies
1
Age
31
XP
1,506
Country
United Kingdom
Code:
16:9 Aspect Ratio (Widescreen) [Ralf]
042EB2D8 3FE38E39
201D43F0 00000001
042EB2D8 3F9BE76D
E2000001 80008000
I want to use Devolution to run this at 576p with full support for both Bluetooth controllers and GBA connectivity, but its own widescreen patch for the game is really janky. I tried to use GeckoLoader to bake this widescreen patch into the .dol but it's admittedly somewhat beyond my skills right now to discern where and how I should hook it. Do I need the mastercode? Should I glean a hook address from the mastercode? Both? I tried using GCFT along with a hex editor to find a good place to hook, but no dice. I suppose the auto tools would have done the same thing but faster.

As far as I'm aware nobody's tried this before and it might not even work (bear in mind it was cracked and you can generate those silly verification files for any GCM) but if it does work, it would open up some games to be played on Devo better than they are on Nintendont.

Cross-posted from GC-Forever.
 

N7Kopper

Lest we forget... what Nazi stood for.
OP
Member
Joined
Aug 24, 2014
Messages
1,123
Trophies
1
Age
31
XP
1,506
Country
United Kingdom
I would've posted this on gc-forever but I lost the password and the password reset system doesn't email me, and I refuse to post on gbatemp anymore.
Since I already went through the trouble of getting the game and testing it I might as well send it your way.

I don't know about those tools you tried, the widescreen code here is very small and it's a bit overkill to inject the gecko code handler to write and check every frame, or several times a frame depending on the hook. So I decided to breakpoint on the address that's checked by the gecko code, and branch to an asm version of the gecko code. That means the execution of the code only occurs every time the game wants to write to that address. It should effectively work the same way as the gecko code but better, though you never really know without testing the whole game.

From what I gather, the code is always writing to make 3D projection widescreen but if the main menu is active it's switched back to 4:3.

Besides the main.dol, this game loads default.dol from the root of the fst, both are identical so you can apply these changes to both of them. However, default.dol seems to be the only one used by the game.

Here's what you need to do:
- Extract default.dol from the game files.
- Open it in a hex editor like HxD.
- Go to dol address 0x818 and you should see the bytes "93 DF 00 10" change them to "48 1C 7E B8"
- Now go to address 0x1C86D0, you should see some debug text, this space is always unused in GC and Wii games so I like to use it for small hacks like this.
- Starting at 0x1C86D0 overwrite the bytes with: 93DF0010 3D20802E 3C003FE3 60008E39 6129B2D8 90090000 3D60801D 616B43F0 800B0000 2F800001 40BE0010 3C003F9B 6000E76D 90090000 4BE38114

Devolution doesn't remove deflicker when forcing progressive scan, so at address 0x167466 you can replace the bytes with 00 00 15 16 15 00 00 to make the game even sharper.
For the record, GCFT didn't even flag up the main.dol of this game - only the default.dol. The main.dol really is unused by the game.

Would it be okay to link an xdelta patch that I made that converts the NKit trimmed dump of this game into the widescreen patched version, for simplicity's sake? Copyrights and copylefts get weird sometimes, and I don't wanna get the Temp in trouble.
 
Last edited by N7Kopper,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    SylverReZ @ SylverReZ: https://i.imgur.com/UEGF5zt.png