tge-was-taken / p4gpc.modloader

Mod loader for the Steam version of Persona 4 Golden
40 stars 12 forks source link

Build status

p4gpc.modloader

Mod loader for the Steam version of Persona 4 Golden

Download

Stable releases can be found here.

Development releases can be found here.

Dependencies

Building

Note: skip this section if you're installing an existing build from the releases page.

By default this is a folder called Mods in the root of the Reloaded installation folder, however can be overwritten in %AppData%/Reloaded-Mod-Loader-II/ReloadedII.json.

Installation

Usage

The following instructions assume the default paths, however they can be changed in the config.

Mod management

Mods can be seperated from each other by creating a folder inside the "mods" folder (p4g install path/mods) with the name of your mod. You can enable them by adding their (case insensitive) name to the 'EnabledMods' list either directly by editing Config.json or through Reloaded. The mod loader will give the highest priority to the entries at the top of the list, meaning that mods below it can't override files replaced by the topmost one.

PAC file replacement

Modified files are placed in a folder named after the PAC file inside the mod folder. The mods are located in the "mods" folder in P4G installation directory by default.

To replace title\logo.bin inside data00003.pac for example, you would place it at (p4g install path)/mods/(mod name)/data00003/title/logo.bin

XWB file replacement

Modified files are placed in a folder named after the XWB file inside the 'SND' folder inside the mod folder. The mods are located in the "mods" folder in P4G installation directory by default.

Sound (track) replacements consist out of a RAW file and a TXTH file. The RAW file contains the raw, unformatted audio data whilst the TXTH is a text based format that describes how the data should be loaded. TXTH is supported by vgmstream, and can be used by playing the RAW file (make sure the TXTH file name is .raw.txth). Use this to test if the audio plays correctly!

A tool such as this one can be used to create these files.

Tracks can be replaced by either their cue name or their index:

Technical info

The RAW file contains the raw PCM data, which would be the contents of the WAV 'data' chunk. The TXTH file is based on the format described here however the loader only implements the necessary subset of options, being:

Advanced usage

Modified files can be loaded without the need of a mod folder if placed in the root of the mods directory. These files take priority over other mods.