2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00
2024-09-16 14:00:37 +02:00

# The Legend of Zelda: Spirit Tracks

A work-in-progress decompilation of The Legend of Zelda: Spirit Tracks.

Supported versions:
- `st-j`: Spirit Tracks - Japan

Currently the decompilation mainly targets the `st-j` version.

## Building

### Requirements

You will need the following dependencies:
* git
* ninja
* python3
* wine (for macOS or non-x86 Linux)
* clang-format (optional)

#### Ubuntu/Debian/Windows (WSL)

You can install the dependencies with the following commands:

```
sudo apt-get update
sudo apt-get install git ninja-build python3
```

#### macOS

You can install dependencies via Homebrew with the following command:

```
brew install git ninja python3
brew install --cask --no-quarantine gcenx/wine/wine-crossover
```

#### Windows (Native)

You will need the following dependencies:
- [ninja.exe](https://github.com/ninja-build/ninja/releases/latest)
- Python (make sure to add it to your PATH during the installation)
- [Git for Windows](https://www.git-scm.com/downloads)

You need to add ``C:\Program Files\Git\bin`` to your system's PATH (not the user one) in order to execute bash scripts properly.

To get objdiff to work properly you also need to add the path to the folder containing ``ninja.exe`` to the system's PATH.

### Instructions

1. Clone the repo using `git clone https://github.com/yanis42/st`.

2. Extract the following TGC archive containing the N64 emulator from the disc of the version you want to build:

  * `mq-j`: `zlj_f.tgc`
  * `mq-u`: `zlj_f.tgc`
  * `mq-e`: `zlj_f.tgc`
  * `ce-j`: `120903_zelda.tgc`
  * `ce-u`: `zelda_ENG_090903.tgc`
  * `ce-e`: `zelda_PAL_093003.tgc`

  Then, extract the DOL file from the TGC archive and place it in the repo as `orig/<version>/main.dol`.

  You can use [Dolphin](https://dolphin-emu.org) to perform both of these extraction steps:
  first, right click on the `.iso` file, select "Properties", go to the "Filesystem" tab, find the correct
  `.tgc` file, then right-click and select "Extract File..." and extract it to your games folder.
  Then, right-click the extracted `.tgc` file in Dolphin, select "Properties", go to the "Filesystem" tab,
  right-click the "Disc" and select "Extract System Data..." to extract the DOL file.

3. Run `python3 tools/configure.py` to generate the build. (Note: on Windows you might need to run ``python tools/configure.py``.)

4. Run `ninja` to build the `st-j` version, or run `ninja <version>` to build another version.

## Development Tools

### objdiff

For local decompilation testing, start the [objdiff](https://github.com/encounter/objdiff) GUI and open this directory as the project directory.

## License

This project is licensed under CC0. Some tools might have their own license.
S
Description
No description provided
Readme CC0-1.0 66 MiB
Languages
C++ 90.2%
C 6.5%
Python 3.3%