mirror of
https://github.com/encounter/ac-decomp.git
synced 2026-03-30 10:57:04 -07:00
master
Implement & link ac_npc_p_sel
Animal Crossing Decompilation

Decompilation in progress of Animal Crossing (GAFE01)
A decompilation of the original N64 version of the game is being worked on here.
Cloning
Use --recursive when cloning to have ppcdis in the repository.
Building
Note
On Windows, the build is known to run disproportionately slow when ran natively, so WSL is recommended.
Docker
- Dump a copy of the game and extract all files.
- Place main.dol, foresta.rel.szs, forest_1st.arc, and forest_2nd.arc in dump/.
- Install Docker.
- Set up the Docker image. If using MacOS or Linux (including WSL), run
chmod +x docker-setup.sh && ./docker-setup.sh. If using Windows, run thedocker-setup.batfile. - Run configure.py (
docker run --rm -v ${PWD}:/ac-decomp ac-decomp python3 configure.py). - Run build.py (
docker run --rm -v ${PWD}:/ac-decomp ac-decomp python3 build.py).
Build manually
Tip
When building manually from a work directory previously used for Docker,
sudo ninja -t cleanwill need to be ran for the build to execute properly.
- Dump a copy of the game and extract all files.
- Place main.dol, foresta.rel.szs, forest_1st.arc, and forest_2nd.arc in dump/.
- Download the CodeWarrior 1.3.2, 1.3.2r, and 1.2.5n compilers and extract them to tools/1.3.2/, tools/1.3.2r/, and tools/1.2.5n/, respectively.
- Install Python, pip, and ninja using a package manager of choice.
- If using an ARM-based device, cmake will also need to be installed.
- Install Python modules from requirements.txt (
pip install -r requirements.txt). - Install wibo
- Wibo is a lightweight Wine replacement that's tailor-made for use with decomp projects. Regular Wine can be used if preferred, but for the purposes of this guide, these instructions will use wibo.
- Download the latest GitHub release and run
install ./wibo /usr/binto install it to the system.
- Install devkitPPC.
- devkitPro Pacman is needed to get devkitPPC.
- Run
dkp-pacman -S devkitPPConce dkp-pacman is installed to install devkitPPC. - Set the
DEVKITPPCenvironment variable to /opt/devkitpro/devkitPPC.
- Run
- devkitPro Pacman is needed to get devkitPPC.
- Set the
N64_SDKenvironment variable to the path of libultra or equivalent headers. Headers from ultralib can be used.- Headers should be located at
$N64_SDK/ultra/usr/include. Gpopmtx'sparammember must be modified to beunsigned intin gbi.h.
- Headers should be located at
- Run
python3 configure.py. - Run
python3 build.py.
Quick Guides
- Dumping Game Files
- Ghidra Setup
- Generating Decomp Context
- decomp.me Basics
- Ghidra Basics
- m2c Basics
- Decomp Basics
Credits
- jamchamb, Cuyler36, NWPlayer123 and fraser125 for past documentation of Animal Crossing.
- SeekyCt for ppcdis and helping setting up the project.
- msg for helping with tools/map.py.
Description
Languages
C
94.5%
C++
3.8%
Python
1.4%
Pawn
0.2%
Assembly
0.1%