• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Guide for adding additional Formes to USUM (extension of Axyn's work for XY, along with improved/streamlined tool)

9
Posts
8
Years
  • Age 32
  • Seen Apr 14, 2024
Part 0, Stuff you need

1) My fork of Axyn's fork of pk3DS(in its own folder, DO NOT put in same folder as regular pk3DS, I built on his code to automate and streamline the process) https://github.com/ABZB/pk3DS-Tingley/releases

2) Regular pk3DS (some elements of the menu are screwed up in my fork, better to use the last release for actual editing)

3) A Hex editor like HxD

4) Your extracted ROM

5) My "List of Locations" & "Plan for adding formes" spreadsheet https://docs.google.com/spreadsheet...ouid=103363226875144008950&rtpof=true&sd=true

6) Rejigger.js https://www.dropbox.com/scl/fi/ot50...igger.js?rlkey=r8enyhz5d4zxwvvr8zl8swish&dl=0 (slightly changed from Axyn's version, credit to him for this)

7) concatenate.js https://www.dropbox.com/scl/fi/zi2d...enate.js?rlkey=t43ul3ftgcf44t6e5wwquitvd&dl=0


8) Setup Rejigger and concatenate by opening them in a text editor and setting the paths to the relevant folders.

Part I, Adding new formes.

1) In the File Checklist tab of the Plan for adding formes spreadsheet, enter the various base formes and new-formes in columns C and E, starting from below 975 Rockruff. (You will want to delete everything in columns C, E, and J through Q, and clear the highlighting - these spreadsheets are not finalized so these are my working copies). We're making a bunch of changes and keeping track of what you need to do (and later what you did) makes things MUCH easier in the long run.

2) This will cause column D to populate with the new internal index number of the new forme, which you will use several times below, and columns F through I to populate with other info used later.

3) Copy files a013, a014, & a017 to a new folder (I recommend sticking backups of them somewhere, you will very possibly screw something up the first few times. I know I did)

4) Use the pk3DS Garc extracter to extract each of those garcs

# Apply each of the following steps for each of the Pokemon you added to the spreadsheet in step 1

5) In a013 (Level up moves), find the file that has the same name as the index number of the base forme (remember, this is column I), copy it, and rename it to the number in column D. (You can copy *any* levelup file, but for Megas you want it to the same, and for alternate formes you usually will follow the same level pattern and leave some moves as is, so this is usually faster/easier).

6) In a014 (Evolutions), copy any file you want. Since these are usually going to be either empty (Megas) or entirely new (other new alternate formes), I usually copy the last blank (just a string of 0s) file, which if you're just starting is 974 (Totem Ribombee), and rename it to the new index number (column D)

7) In a017 (Personal (main Pokemon data)):

a) Go the numerically last file (it will be 1 more than the last index number, if you haven't made any edits at all yet it will be file 976), and rename it to be 1 more than the last index number you now have in column D (e.g. if you added 3 formes, they are 976, 977, & 978, so rename the old 976 to 979). Obviously only do this once per time you follow this entire instruction-set. Open this file (it has a redundant copy of all the information in the individual files above, both pk3ds and the game will crash if the copies don't match).

b) Find the file that has the same name as the index number of the base forme (remember, this is column I), open it in your hex editor, and then make a copy of the file, named to the number in column D, and open that file too.

8) Open the old file (column I).

9) You now have two files open - the old file, and the new file.

In one file:

a) Change offset 0x20 to be the total number of formes, which will be automatically computed for you and displayed in column F

b) Change offsets 0x1c and 0x1d to the values in columns G and H respectively.

c) Copy everything in that file and overwrite the other (you will be making all your edits to the new forme in Pk3ds).

10) Run concatenate.js, then repack the GARCs and paste them back into the appropriate place in your ROM folder

11) Open pk3ds and verify that the newly added Pokemon are showing up. You can now edit everything to make them work!

12) If they are not showing up, or they are showing up as only having the index number and a hyphen, something went wrong, probably with steps 9a or 9b. Worst case just start again from step 3 with the backups you made.

13) The Pokemon will now be fully functional within the game, although it will look the same as the base forme.

14) Note that at this time, unless you apply that patch from the UPR that makes
Megas *never* revert, any Pokemon with a Mega set will automatically revert to forme 0 no matter what, except in a couple of edge cases involving interactions with Abilities that change forme (basically, if a Pokemon changes forme due to Ability (like Mimikyu) and then Mega Evolves, it will get "stuck" in the forme it changed to, although saving and restarting fixes the stucknes). As a result, you will have to choose between "alternate forme" and "Mega Forme" (I plan on trying to figure out a way to have this not happen, but I need to learn Assembly to even start).

15) Further note that the game cannot handle having formes that are not consecutive, so if for example you wanted to add a Mega Venusaur Y, you would have to move the current Mega Venusaur files to a different spot and add the new mega forme after (note that you will need to follow step 9a and 9b for every forme plus the base, and also move the files in each of the three mentioned files for the forme you're moving), OR overwrite the following forme and/or move that one somewhere else.


Part II, Adding new textures

0) Only need to do these once.

a) Open "List of Locations", delete the "Edited" tab, then make a copy of the "Clean Copy for edit" tab, rename "Edited". Make sure that "Plan for adding formes" is closed while you do this, otherwise it will get confused and you will have to fix the broken links/formulas (not hard if you know excel at all but annoying). Do this for each fresh hack, then keep that pair of both excel files as a permanent ongoing record of what you've done.

b) In Rejigger.js, on the second line, type the directory your extracted a094 folder is in, e.g. between the quotes, e.g. the line could read

let rootFolder = 'E:/USUM/USUM Textures';

Place Rejigger.js in the that same folder (e.g. if you have E:/USUM/USUM Textures/4_g, then E:/USUM/USUM Textures/Rejigger.js).

c) As importing new models into USUM is an open problem, all we can do are texture edits.

1) I will assume that you already have done so, and have the nine files that compose the model, texture, and animations ready to go (these take the most time, I actually only do a couple a day, which is part of why I made all these spreadsheets to keep track of what I've done).

2) Add all of your added Formes in the Plan for texture edits tab of Plan for adding formes sheet, column D. This will populate the other columns. Columsn E and F are for your own use for planning what kind of edits you want to make. Note that this tab will not function properly if the List of Locations spreadsheet.

3) For each of your completed texture-edits, rename the 9 files from xxxxx_0 through xxxxx_8, in the same order as they are originally numbered. The correct value of xxxxx will be shown in column B.

4) move the renamed files into your extracted a094 folder (make sure it is named 4_g)

5) Run Rejigger.js in command line, you will need to install the javascript thing to be able to run the command, which is node rejigger.js. You will need to first type cd <path to the rejigger containing folder>, e.g. using example path from above:

cd E:/USUM/USUM Textures

then

node rejigger.js

6) Pack up the GARC with the regular pk3DS, and move it back to its location in your ROM folder, then close pk3DS

7) In the folder you placed my special version of pk3DS, there is a text file, changed_indices.txt. Type in the base-forme index numbers (e.g. if you say added a Mega Fearow, the number would be 22) of all the Pokemon who you just added models for, one per line. Save the file, then open this pk3DS version (the first time you will need to select your ROM, after that it will automatically open it as pk3DS usually does. If you need to switch to a different ROM, make sure that changed_indices.txt is empty, then open and switch to the new ROM folder, then close pk3ds and first type in your index numbers - if that index number file is empty, it will not do anything).

8) pk3DS will open but hang for anywhere from a few moments to a few minutes, depending on how much you just added. Once it loads and you're at the main window, you're done! close pk3ds and IMMEDIATELY DELETE ALL LINES FROM changed_indices.txt let's not have any accidents.

9) If you added more than one forme for a given Pokemon (e.g. you added Mega Fearow X and Y's custom stuff at the same time), you will need to run this again, one time per added texture/model grouping (make sure you delete any lines for Pokemon that had fewer added in this batch though!)

10) I recommend checking that everything went right ASAP, it's not hard to screw something up and have all the models be off-by-one.

11) If everything is good, in Edited in List of Locations, insert lines underneath the last forme of the Pokemon you just inserted, type in the new Forme name in column C, and copy the formulas down. This will allow you to easily see what files are for which Pokemon in your changed model listing. (if everything is not good, revert to your backup of a094 from before you started this and try again).



12) NOTE:

a) The large static portraits (what you see in the Pokemon Center healing screen) are located in a244, but I haven't figured out how to add to them. Right now new formes default to having Bulbasaur there.

b) Same for the box/party icons in a257 (although there they default to the Pokemon's base forme).

c) Similarly, the positioning of the model for Refresh is recorded *somewhere* (I
suspect a326 but it doesn't seem to work the way I thought at the very least), so
if you, for example, have an Onix-based thing for say an alternate Bulbasaur, you
will not be able to reach most of the model, or sometimes *any* of the model. Also, if you use a model that was not intended to be accessible in Refresh (like a Mega), in Refresh it will display Pikachu instead (but otherwise function normally).
 
Last edited:
Back
Top