WiiRd forum

Wii & Gamecube Hacking => WiiRD Remote Debugger => Topic started by: Igglyboo on November 11, 2008, 02:05:46 AM

Title: Hook
Post by: Igglyboo on November 11, 2008, 02:05:46 AM
What does the "Hook" function in WiiRD do?
Title: Re: Hook
Post by: TNTkryzt on November 11, 2008, 02:13:39 AM
I assume it's the entry point, replacing a frequently executed opcode with a branch to the code handler.
Title: Re: Hook
Post by: Link on November 11, 2008, 06:36:40 AM
Quote from: TNTkryzt on November 11, 2008, 02:13:39 AM
I assume it's the entry point, replacing a frequently executed opcode with a branch to the code handler.

What he said.. the hook command is kinda the "launch game" command.
WiiRd sends to Gecko OS: "Please attach to the current game" - Gecko OS must be in the menu for that.. besides it can also pass all options to Gecko OS then:

hook --> Launch game regularly (VI hook)
hook pause --> Launch game paused (this is what WiiRd GUI does.. the game is loaded into memory but in last second it isn't yet started)
hook pal60 --> Launch game with PAL60 forced
hook pal50 --> PAL50 forced
hook ntsc -->NTSC forced
hook vidtv --> VIDTV patch
hook vi --> VI hook
hook wiimote --> Wii remote hook
hook gcpad --> GC pad hook

and well options can be mixed:

hook pause pal60 vidtv gcpad --> PAL 60 forced, VIDTV patch applied, using GC Pad hook and launching paused..
Title: Re: Hook
Post by: Igglyboo on November 11, 2008, 07:46:08 PM
Im talking about in wiird
You can right click some values and they have the option to hook them.
Title: Re: Hook
Post by: Link on November 14, 2008, 06:27:09 AM
then you mean WiiRD GUI.. WiiRD is the console!

Doing that: means you rewrite the assembly code at that location so that a branch to the WiiRd code handler is being created. That's kinda helpful if you have applications requiring master codes or for apps trying to overwrite your current hook!