Skip to content

Commit

Permalink
Merge pull request #8 from BrawlerAce/main
Browse files Browse the repository at this point in the history
Updated publishing + audio guides
  • Loading branch information
AnimatedSwine37 authored Oct 16, 2023
2 parents 2161bee + 58bd8e5 commit 0b41c60
Show file tree
Hide file tree
Showing 14 changed files with 86 additions and 10 deletions.
Binary file added assets/images/audio/foobar-example.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/getting-started/personaeditor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions audio/audio-addition.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Data for BGM is stored as

where the `XX XX` denotes the BGM ID in hexadecimal.

Follow the guide for changing event music, but call the ID of the corresponding song in hexadecimal. For example, to change event BGM to `679`, `680`, ..., change `XX XX` to `A7 02`, `A8 02`, ...
Follow [the guide for changing event music](event-audio-editing), but call the ID of the corresponding song in hexadecimal. For example, to change event BGM to `679`, `680`, ..., change `XX XX` to `A7 02`, `A8 02`, ...

## Adding New Battle Music
Follow the guide for changing battle music, but instead of selecting from the default selection of battle BGMs, enter the ID of the new song added. For example, to change a battle BGM to `00679_streaming`, `00680_streaming`, ..., change the music ID to `679`, `680`, ...
Follow [the guide for changing battle music](audio-replacement), but instead of selecting from the default selection of battle BGMs, enter the ID of the new song added. Unlike with replacing the default BGM, you don't need to subtract 1 from the streaming ID. For example, to change a battle BGM to `00679_streaming`, `00680_streaming`, ..., change the music ID to `679`, `680`, ...
12 changes: 9 additions & 3 deletions audio/audio-replacement.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ games: ['P3F', 'P3P', 'P4G', 'P5R']

## Replacing Audio Normally

If modding P3F or P3P on PC, you can simply drag and drop the files in your mod folder. For P4G or P5R on PC, AWB Emulator is the recommended method to replace audio as it allows audio replacement without repacking and distributing the entire sound archive. Documentation on AWB Emulator can be found [here](https://sewer56.dev/FileEmulationFramework/emulators/awb.html).
If modding P3F or P3P on PC, you can simply [replace the files](/persona-modding-docs/getting-started/replacing-files). For P4G or P5R on PC, AWB Emulator is the recommended method to replace audio as it allows audio replacement without repacking and distributing the entire sound archive. Documentation on AWB Emulator can be found [here](https://sewer56.dev/FileEmulationFramework/emulators/awb.html).

{% tabs awbemulator %}
{% tab awbemulator P3F %}
Expand All @@ -33,10 +33,16 @@ For example, if editing music, the corresponding audio would be placed in `(mod
{% endtab %}
{% endtabs %}

For P4G and P5R, the files should be named according to their streaming ID; the file naming format is `(streaming ID - 1)_(whatever you want here)`.

For example, to replace I'll Face Myself in P4G, find the ID that corresponds to that song. Its BGM ID is 9, which corresponds to a streaming ID of `38`.

{: .todo }
Make this more specific including file names
![]({{ site.baseurl }}/assets/images/audio/foobar-example.png)

Therefore, the file could be named anything with `37` in the front, such as but not limited to:
* `00037_streaming`
* `37`
* `037_I_ll_Face_Myself`

## Repacking an AWB file

Expand Down
5 changes: 1 addition & 4 deletions audio/event-audio-editing.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ If switching from playing one song to another, P3F and P4G default to using a su
{: .info }
> It is possible to edit event music fully without editing this file by forcing specific music to play in the PM3 file for the event! However, many events have their music calls stored here, so editing this file can reduce redundancy.
Many of P4G's events call music at the beginning; this data is stored in `init.bin/event/cmm.bin/cmmEventBGM.dat`. Editing this file requires the use of [010 Editor](https://www.sweetscape.com/010editor/) and [several templates](https://github.com/tge-was-taken/010-Editor-Templates) designed for file types supported by the Persona games. Extract these templates to a separate folder.
Many of P4G's social link events call music at the beginning; this data is stored in `init.bin/event/cmm.bin/cmmEventBGM.dat`. Editing this file requires the use of [010 Editor](https://www.sweetscape.com/010editor/) and [several templates](https://github.com/tge-was-taken/010-Editor-Templates) designed for file types supported by the Persona games. Extract these templates to a separate folder.

Extract `cmmEventBGM.dat` using Amicitia or Persona Editor, then open it in 010 Editor. By running a template on it, we can use a more readable format. Open a template by clicking the Run Template button, then the Open Template button, or press `Ctrl + F5`.

Expand All @@ -141,8 +141,5 @@ You can change BGMIndex for a given event here to change the music that plays at

After editing the file, place it in `(mod folder)/FEmulator/PAK/init.bin/event/cmm.bin`, where `init.bin` and `cmm.bin` are folders.

{: .todo }
> Figure out whether this is BGME compatible
{: .todo }
> Figure out if it is possible to add more entries for different events that aren't already present
6 changes: 6 additions & 0 deletions getting-started/extracting-files.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ The easiest way to extract files from these archives is [Amicitia](https://githu

![]({%link assets/images/getting-started/amicitia.png %})

### PersonaEditor GUI

[PersonaEditor](https://github.com/Meloman19/PersonaEditor/releases/tag/1.6) is an alternative program. While Amicitia is preferred in most cases, PersonaEditor is more useful for some file types, and features limited built-in text editing support. It has a similar UI to Amicitia.

![]({%link assets/images/getting-started/personaeditor.png %})

### Command Line
Although Amicitia is the most user friendly, it's not good for batch extracting files as you can only select one at a time. If you need to perform batch operations you can download [PackTools](https://github.com/tge-was-taken/AtlusFileSystemLibrary/releases/latest).

Expand Down
66 changes: 65 additions & 1 deletion getting-started/publishing-a-mod.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,69 @@ nav_order: 4
games: ['P3P', 'P4G', 'P5R']
---

Now that you have [made a mod](making-a-mod) and [replaced some files](replacing-files) with it, you'll want to share your creation the world.
Now that you have [made a mod](making-a-mod) and [replaced some files](replacing-files) with it, you'll want to share your creation with the world.

{: .info }
> The majority of Persona mods are posted on [GameBanana](https://gamebanana.com/). This guide will assume you are publishing your mod there.
You will need to set up a mod page to get the mod ID, export your mod with the ID, and then post the mod on your mod page.

## Setting up a mod page

It is important to set up a mod page first, as the ID of your mod page is required in order to set up automatic updates in Reloaded. Otherwise, mods will not be available for one-click install on GameBanana and they won't receive updates.

Go to the page of the game you're modding for, and click the Add button.

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/gb-add.png)

Select an appropriate section for your mod; most mods will simply fall under `Mod`, but some may fall under `Sound` for music/SFX mods, `Tool` for applications related to mod making, etc.

Fill out the required fields:
* Main
* Mod Title
* Mod Category: *Choose the category that best describes your mod.*
* Body
* Ownership
* Is this a port?
* Did you create this Mod?
* Authors
* Screenshots
* Files: *Placeholder file(s) can be uploaded for now, but make sure to add the relevant mod files before posting the mod publicly.*
* Settings
* Access: ***Set this to private!***

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/gb-private.png)

{: .warning }
> Before saving, **remember to set the mod access to Private!** Otherwise you will publicly publish a mod with no content in it!
Click Submit at the bottom, and you will be taken to the mod page. Your mod ID is found in the URL. Save this for the next step!

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/gb-id.png)

## Setting Update Support

In Reloaded, select your mod, click Edit, and go to **Update Support**.

Click on GameBanana, then set `ItemId` to the mod ID you got previously. Also set `ItemType` to the category your mod is in (Mod, Sound, etc).

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/r2-update-support.png)

## Publishing Your Mod

Now select your mod and click Publish. Set your Publish Target to GameBanana, set a readme and/or changelog file as desired, then click Publish.

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/r2-publish.png)

{: .info }
> For more details, click on Publishing Tutorial or go to the [Reloaded II documentation](https://reloaded-project.github.io/Reloaded-II/CreatingRelease/).
After publishing your mod, it will export the files to the directory shown in the Publish Mod window and automatically open a new window to that filepath.

![]({{ site.baseurl }}/assets/images/getting-started/publishing-a-mod/export.png)

There will be two files:
* A compressed file with your mod in it
* A JSON file with update information

Upload both of these files to the Files section of your mod page, finalize any other fields you may have left as placeholders, set mod access to Public, and then click Submit to publicly publish your mod!
3 changes: 3 additions & 0 deletions getting-started/replacing-files.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,6 @@ PAK archives can have many different file extensions like `PAK`, `ARC`, and `BIN
To replace these, open your mod folder as before, but then create a folder named FEmulator. Inside this new folder, make another folder called PAK. Then, in the PAK folder, create a folder with the name of the PAK.

If you noticed while viewing the PAK in Amicitia that your file was named something like battle/effect/z0.tmx, treat everything before z0.tmx like a path, and create folders accordingly. PAKs can also be nested within PAKs; if this happens, just create a folder for the nested PAK and repeat until you get to the file you're actually replacing.

## Other Files
Certain files in certain games are handled differently (for example, P4G music replacement). These are covered in their own sections.

0 comments on commit 0b41c60

Please sign in to comment.