Twilight Hack

From GameBrew
Jump to: navigation, search
Twilight Hack
Twilight Hack icon
General
Author(s) Team Twiizers
Type Exploit
Version 0.1 beta2
Links
Download
Source

The Twilight Hack was the first way to enable homebrew on a Wii without hardware modification. The Twilight Hack was used by playing a hacked game save for The Legend of Zelda: Twilight Princess which executes a homebrew application from an SD card. Examples of such homebrew .elf or .dol files can be found on the Homebrew applications page. The Twilight Hack was created by Team Twiizers.

Twilight Hack 0.1beta1 is compatible with System Menu up to 3.3, 0.1beta2 is compatible with System Menu 3.4. The twilight hack is not and never will be compatible with System Menu 4.0 and up. Use another exploit from now on.

The source code was written to be readable, portable and reusable; most of the code was reused for Indiana Pwns, and you are encouraged to use it to create your own savegame exploits (provided you follow the licensing terms of the codebase).

Fanmail can be left at Twiizers Fanmail.

Contents

Usage and Installation

Required materials:

Inner disc circle with serial

Inside the zip file you will find versions of the hack for all three regions. You may copy all of them to your SD card, but you will need to choose the correct one to copy to your Wii based on your version of Zelda: Twilight Princess. USA users, additionally, need to determine the correct save slot to load once inside Twilight Princess. The easiest way to check your version is to compare the text string which is on the inner circle of the data surface with the ones below.

Region Inner circle text File Save slot
Europe/Australia (EUR) RVL-RZDP-0A-0 JPN /private/wii/title/rzdp/data.bin Twilight Hack
Asia (JPN) RVL-RZDJ-0A-0 JPN /private/wii/title/rzdj/data.bin Twilight Hack
America (USA) RVL-RZDE-0A-0 JPN /private/wii/title/rzde/data.bin TwilightHack0
America (USA) RVL-RZDE-0A-0 USA /private/wii/title/rzde/data.bin TwilightHack0
America (USA) RVL-RZDE-0A-2 USA /private/wii/title/rzde/data.bin TwilightHack2

Step by Step

  1. Ensure your SD card is formatted as FAT. By default SD cards are formatted as FAT, so if you're not sure you can skip this step.
  2. (Optional) If you have an existing Zelda save that you want to backup, do so before proceeding:
    1. Put your SD card in your Wii and turn it on.
    2. Go into Wii Options --> Data Management --> Save Data --> Wii
    3. Find your Zelda save, click on it, click "Copy", and click Yes
    4. Put your SD card in your computer, and copy the "private" folder from the card to a safe place.
  3. Copy the "private" directory from the Twilight Hack download to the root of your SD card.
  4. Take your homebrew Wii executable (elf or dol file) and save it in the root directory of your SD card as "boot.elf" or "boot.dol" as appropriate.
  5. Put your SD card in your Wii and turn it on.
  6. Go into Wii Options --> Data Management --> Save Data --> Wii.
  7. Find your Zelda save, click on it, click "Erase", and click Yes.
  8. Open the SD card and select the "Twilight Hack" save that corresponds to your game region. Note: Some people are having problems with the Wii not "seeing" the save file on the SD card. If you are experiencing this, try setting the archive bit for the data.bin file - in Windows this can be either be done from the file's properties dialog (right click on it in Windows Explorer and check the box) or from the command line using "attrib +a <path to data.bin>". More info at #wiihelp on Efnet.
  9. Click copy and then yes. Now exit out of the menu.
  10. If you are using System Menu 3.4, you must immediately put the Twilight Hack to use. Turning off or running some other channel or game will have the System Menu delete the savegame again, and you'll have to start over.
  11. Insert The Legend of Zelda: Twilight Princess game disc and run the game.
    • If you have the USA version of the game, load the "TwilightHack0" or "TwilightHack2" version of the game as appropriate (see above).
    • Otherwise, load the only "Twilight Hack" save game.
  12. Once in the game, either walk backwards or talk to the man standing in front of you.
  13. Follow the instructions listed on the screen.
  14. Enjoy.

Troubleshooting

Changelog

0.1beta2

0.1beta1

0.1alpha3b

0.1alpha3a

0.1alpha3

Explanation

The hack exploits a buffer overflow error caused by loading a specially crafted save file for Twilight Princess. The save file stores a custom name for Epona, Link's horse, that is much longer than what the game would usually allow, in fact it even contains a small program. While the game doesn't allow you to manually enter a name this long it doesn't check the name in the file. When the game tries to load the name into memory it inadvertently drops the small program into memory filling not only the "horse name" buffer but adjacent ones. In a round about way these regions of memory happen to be designated the next region the console should execute. As you can see the save file is specially crafted indeed. Once the code loads it runs either a "boot.elf" or "boot.dol" file from the root of the SD card. If the boot.elf and bootmini.elf that loads HackMii exists on the root of your SD Card, you can use it to then install BootMii IOS, BootMii Boot2 (if compatible), or, importantly, the Homebrew Channel.

FAQ

Yes.
Not directly. Though you can use the Wii Gamecube Homebrew Launcher once you've got your Wii ready for homebrew.
No. These tools merely change the container file format, it does not convert between GameCube/Wii code.
No, after the 4.0 update the Twilight Hack was completely blocked. However bannerbomb works on 4.0 - 4.2, LetterBomb works on 4.3, and Smash Stack and Indiana Pwns work on 3.0 - 4.3.
Yes, LEGO Indiana Jones and Super Smash Bros. Brawl could be used.
There's no easy way to merge saves between files. Use the Twilight Hack to install the Homebrew Channel, then copy your old savefile back into place.

Main FAQ Page: Wiibrew FAQ

Known bug

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox
Make a donation