A decompilation of Pikmin 2 (USA) brought to you by fans of the series.
Go to file
2021-11-07 13:21:57 +00:00
asm allow linker to auto-generate _rom_copy_info and _bss_init_info 2021-11-06 23:35:48 -04:00
include Update TParse.h 2021-11-07 13:21:57 +00:00
sha1 Initial commit 2021-09-27 21:57:49 +01:00
src Update ebiP2TitleChappy.cpp 2021-11-06 23:26:11 +00:00
tools update elf2dol 2021-11-06 23:35:48 -04:00
.clang-format Edit format document 2021-10-14 20:57:34 +01:00
.gitignore update gitignore 2021-10-14 11:46:07 -04:00
asmdiff.sh Add makefile for elf2dol, Edit asmdiff.sh, Add patch_linker.sh 2021-10-04 10:10:08 -04:00
calcprogress.py repair calcprogress to conform with 2.6 2021-11-06 23:47:04 -04:00
format-files.py Fix formatfiles and format .c files 2021-11-04 00:38:18 +00:00
ldscript.lcf allow linker to auto-generate _rom_copy_info and _bss_init_info 2021-11-06 23:35:48 -04:00
linker-map.txt recreated source filesystem 2021-09-29 17:30:58 -04:00
Makefile update elf2dol 2021-11-06 23:35:48 -04:00
obj_files.mk allow linker to auto-generate _rom_copy_info and _bss_init_info 2021-11-06 23:35:48 -04:00
patch_linker.sh use 2.6 linker 2021-11-06 22:45:29 -04:00
README.MD Compiles again! 2021-11-04 00:19:56 +00:00

Pikmin 2

Pikmin 2 decompilation to C++/C

- INFORMATION! -

The ROM this repository builds can be shifted! Meaning you are able to now
add and remove code as you see fit, for modding or research purposes.

It builds the following DOL: pikmin2.usa.dol: sha1: 90d328bf8f190c90472e8c19e7e53c6ad0fe0d1a

Credits

  • Revo
  • intns
  • EpochFlame
  • GibHaltmannKill
  • kiwi
  • shibboleet
  • wowjinxy
  • nerduminer
  • sodium
  • JHawk
  • Meeo

Building

Required Tools

Instructions

  • WINDOWS ONLY STEP:
    • Launch msys2(Provided by devkitPro) and run the command pacman -S gcc.
  • OPTIONAL:
    • Obtain a clean DOL of Pikmin 2 USA 1.0 and place it in the base working directory and rename it to baserom.dol.
  1. Download GC_WII_COMPILERS.zip from (https://cdn.discordapp.com/attachments/704241951972524063/801641758249320478/GC_WII_COMPILERS.zip) and extract it to tools/mwcc_compiler/.
  2. Create a copy of the 2.7 folder in tools/mwcc_compiler/ and name it 2.7e.
  3. Run the make command.

Modifications to the CW compiler

In order for a correct compile to occur, the v2.7 linker executable is modified as follows:

Offset From To
0x36510 0x74 0x75

The byte's value is changed from 0x74 to 0x75 at offset 0x36510 (fixes an issue regarding destructor generation)

When compiling the project, this patch is automatically applied, if it fails to patch you can also patch the executable yourself with a hex editor

Project Organisation

  • For each namespace that types and functions are contained within, create a folder. E.g. the structure Game::GameSystem will go in include/Game/GameSystem.h.
  • The exception is only when adding extra folders becomes useless, for example having to add multiple folders that are empty, you can instead opt for creating a header file with the namespace's definitions inside.
  • The project is actively formatted using .clang-format, for a consistent code style.

Progress

DONE

WIP