Pikmin 2 instructions

From Pikmin Technical Knowledge Base
Jump to navigation Jump to search

Helpful instructions for editing and handling Pikmin 2's files. This guide assumes you have some basic knowledge on navigating folders, opening files, using commands, etc. See obtaining a game's files if you are unsure on how to do so.

You can view and edit a lot of the game's files. You can read them without any worry, but if you want to change them and have those changes apply in-game, see saving changes in general instructions.

To do: Instructions for how to edit music.

Tools and files[edit]

Here are some prominent files that come up when modding.

.DOL: Segmented executable binary format which contains the games compiled source.
.SZS: Archive files similar to .ZIP or .RAR archive files. SZS files are RARC archives compressed with Yaz0 compression.
.ARC: Archive files similar to .ZIP or .RAR archive files. ARC files are RARC archives not compressed with Yaz0 compression.
.TXT: Generic plaintext files. Use Notepad++ to preserve the Shift-JIS encoding.
.BMD/.BDL: Proprietary 3D model files.
.BMS: Sequenced audio files, similar to MIDI but more advanced. List
.CND: Files that control how various sequences in a BMD file are randomly chained together in a complex system. Used for cave music. 
List
.AST: Streamed audio files. List
.AW: Soundbank files. Usually named wScene in Pikmin 2.
.BMG: Used to store in-game text strings.
.BLO: UI screen data.
.BTI: Textures.
.BTK: Animated textures.
.STB: Cutscene data.
.THP: Prerendered videos (GC/Wii)
.WEBM: Prerendered videos (Switch)
.JPC: Particle effect container. List
.JPA: Particle effect.
.BCA: Full animation data.
.BPK: Animation data. (still being researched)
.BCK: Keyframed animation data.

Here are some prominent tools:

Lunaboy's RARC Tools- Used for extracting and converting RARC archives. For szs files, simply rename the converted file from file.arc to file.szs.
Notepad++ - Used for editing text files, many of which need to preserve Shift-JIS encoding.
Gen & Route Editor  - Used for editing overworld generation and pikmin carrying routes.
Drought's Cave Creator - Used for creating and modifiying cave files, cave lighting, and cave unit definition files.
Pikmin 2 Sound Modding Toolkit - Used for modyfing sounds in the game.
JAIMaker - Used for creating custom sequenced music as BMS files. Interactive music and cave music require additional hex editing.
JATAST - Used for converting .wav files into .ast files for streamed music.
pikminBMG - Used for editing text in the game.
pyblo2-gui - Used for modyfing blo files.
FinModelUtility - Used for converting BMD files to formats that can be imported into any 3D modeling software. 
SuperBMD - Used for converting FBX and DAE files back to BMD.
RiiStudio - Used for BMD materials editing. (Pish don't kill me GUI is just easier for now)
obj2grid - Used for converting between .OBJ 3D files and pikmin 2's collision formats.
GameCube File Tools - Used for modification of many GameCube/early Wii era formats, notably BTI files. It can also compress .arc archives to szs.
Hex editor - needed for additional editing of other files such as .BIN binary files. An editor of choice is HxD: (https://mh-nexus.de/en/hxd/)

More tools can be found in Hocotate Hacker if needed. Compiled builds for many of these tools are for Windows, but macOS and Linux users can compile many from source.


A page listing the game's internal filesystem is here, useful for keeping track of where editable files are.

Cave editing[edit]

You can make custom caves with Drought's Cave Creator.

See this page for cave generation specifics.

The BgmList files in user/Totaka control what cave song is used for each sublevel. BgmList_Tutorial.txt is used for Valley of Repose caves, BgmList_Forest.txt is used for Awakening Wood caves, BgmList_Yakushima.txt is used for Perplexing Pool caves, BgmList_Last.txt is used for Wistful Wild caves, and ChallengeBgmList.txt is used for caves in Challenge Mode. When adding more sublevels to any cave, you must remember to add more cave songs to the applicable BgmList text file, or else the game will crash.

You can change the listed CND file to change what song plays in a sublevel.

To add completely new cave music tracks,

1) Make a new BMS file in AudioRes/Seqs/Seq.arc called new_09.bms or so in order, 9, 10, 11, etc

2) Make a new CND file in AudioRes/Conductor.arc new_09_0.cnd, just the BMS name with _0 (leave the CND blank if you don't want interactivity, or see the CND file guide below to make a full track.)

3) Add the new BMS in the user/Totaka/BgmList.txt after the new_0-8

4) Add the new CND in user/Totaka/trackMap_Cond_T.txt. If not doing interactivity, copy paste new_00's entry with the new CND's name; otherwise, see the cave music guide for more details.

5) Add a new wScene for your song using the Sound Modding Toolkit (see guide below), new_09 will use wScene46.aw and so on in order. wScene48.aw is used for the Submerged Castle theme and Waterwraith approaching theme, so it's a good idea to skip from new_09.bms to new_12.bms so you skip to wScene49.aw.

6) Set the new song to be used in the applicable BgmList file for your area/challenge mode BgmList.


Overworld editing[edit]

You can edit overworld generation with the Gen & Route Editor

See this page for overworld generation specifics.


When replacing the music for overworlds, it's important to note which wScenes and BMS files are used.

Valley of Repose - n_tutorial.bms, uses wScene_15.aw

Awakening Wood - forest.bms, uses wScene_2.aw

Perplexing Pool - yakushima.bms, uses wScene_3.aw

Wistful Wild - last.bms, uses wScene_4.aw


Model replacement[edit]

Custom sounds and music[edit]

Custom streamed music can be made with JATAST, a command line tool for converting WAV files to AST files. When converting a .wav file, have the loop points be contained in the .wav file itself. It is important to have new .ast files encoded with ADPCM4, as this helps with disc read speeds. To convert .wav files to ADPCM4 .asts, run this in a command prompt or terminal: jatast yoursong.wav newsong.ast -encode-format adpcm4

Custom sequenced music can be made with either flaaffy (command-line) or JAIMaker (GUI-based), tools that convert MIDI files to BMS files. For non-interactive sequenced music (such as the world map theme and high scores theme), a simple MIDI conversion will suffice. Review this document to see what instruments you can use for your song depending on what bms you're replacing (if you're not editing wScenes with the Sound Modding Toolkit, that is)

If you want interactive overworld music, or randomized interactive cave music, see these two guides:

Creating interactive area music

Creating interactive cave music

Replacement sounds, custom samples, wScene editing + creation, and new instruments can be done with the Pikmin 2 Sound Modding Toolkit. This page outlines the process, as well as a process for doing custom sound effects.


Running your modified game[edit]

See General instructions#Running a modified game.