First things first: the Creation Kit is not a requirement, but it probably makes your job a little bit easier (it does for me). If you don't want to mess with the Creation Kit and would rather stick to Fo4Edit, totally fine. Download and install the tools I've mentioned at the end of the article. Notepad++ is also not a requirement, but I recommend you use it in place of our usual Windows Notepad. It just works is a better tool overall.

Part 1: Finding the bug

You'll need a list of weapons you want to check. If you already know which weapons you want to fix, proceed to Part 2. If not:

Open up Fo4Edit and don't select OR deselect any mods, keep your load order intact here. Go into your weapon mods, check the Weapon tab and get the name of the weapons you want to check. Do keep in mind that there are mods/patches/etc that can overwrite names, so always check if the record is yellow. As you can see, the Honey Badger from SREP has an unique Editor ID on both ESPs, but the Reapers patch has a different name, thus overwriting the original name.





Part 2: Preparing to debug (Optional):
You can either create a new character for testing purposes, or use your current character. It's totally up to you.

  • If you want to use your current character, save your game in a city or settlement (preferebly).
  • If you want to create a new character and avoid the whole 2077 scene, try to use StartMeUp, an early save (outside of Vault 111) from your current character, or download a gamesave from Nexus.

After you do either of these, teleport to Fallout 4's Dev Room. It has no ambient sounds or musics, so it's perfect for sound adjustments. Open up your console and use the COC command COC QASMOKE. If you want to get out for some reason, use the COC command again, but replace QASMOKE with the Cell ID you want. You probably won't need to worry about getting out since we can just load that particular save we made after we are done.

Part 3: Testing the weapon
If you still don't have the weapon somewhere, use the Help command to get the Weapon ID and give yourself the weapon.
help [weapon name] 4 weap to get the weapon ID, and then, player.additem [weapon ID] to get the weapon.

Equip your weapon of choice and enter a Power Armor. Walk around, run, sprint... If the steps are too fast, that means one of two things:
1. The mod doesn't have a custom 1st person Power Armor animation, or 2. The mod does have a custom animation, but it's not being loaded correctly.
What you're aiming here, is to try these things while in Power Armor:
  • Walking (as if you're overencumbered)
  • Running (it's faster than walking, but it costs no AP since you're not sprinting)
  • Sprinting
  • Walking while aiming.
  • Walking with the weapon lowered (if you're using the Lowered Weapons mod, which I highly recommend)*

If any of them feel weird and/or have too fast footsteps, then you can change it. What I like to do to see if it's good is changing into 3rd person, timing the sound between each footstep, and then comparing the timing with the same type of movement while in 1st person. I do this for each movement I previously mentioned. Open notepad (or any text editor) and write which weapons and which movements of each weapon you want to change. This is very important.
Remember that since each animation has one file, that means each movement is also one file. The files for each set of movement are:

  • Walking: WPNWalkForwardReady
  • Running: WPNRunForwardReady
  • Sprinting: WPNSprint
  • Walking while aiming: WPNWalkForwardSighted
  • Walking with the weapon lowered: WPNRunGunDown

Note that the files themselves already tell you which animation they're supposed to be. Walk, run and sprint are self-explanatory. Ready means the weapon is on your hands and you can see them, so they're ready to be fired. Sighted means you're using iron sights while walking, and Down is when you run into a wall, so the character just lowers down their weapon.

* The Automatically Lowered Weapons mod re-uses the cover animation for the weapon to be lowered. That means the animations in most mods will be off while in Power Armor, and will need to be readjusted.


Part 4: Creation Kit
You're more than free to try to do these in Fo4Edit, but it's been easier for me using the creation kit so... Yeah.

  • Download the Bethesda.net launcher and create a Bethesda.net Account. After you're logged on, head into Games, select Creation Kit: Fallout 4, and install it.
  • Download and install F4 Creation Kit Fixes. There are instructions for its installation in the mod page's description. It's practically drag n' drop.

Open up the Creation Kit. After it's loaded up, go for File, and Data...


Find the esp for the mod you want. Click on it, click on Set as Active File, and then Ok. From now on, anything you do, DON'T SAVE, DON'T PRESS CTRL + S, ETC. We're only setting an active file now for our jobs to be easier. Setting a file as active on CK means that anything, and I really mean ANYTHING, you do here will be saved inside this plugin, modifying it.

I'm not sure if this applies to NMM or MO2, but you can open up Vortex and re-deploy your mods. Vortex will then warn you that a file was modified and ask you if you want to keep the modified one, or restore the original file. You'll want to choose to restore the original files. Don't rely on this though.




Select the "Show only active (*) forms" box, and type a 0 in the filter field. Sort by Form Type, and find the Race type. Open up the one that has a PowerArmor on its editor ID or something. If there's no PowerArmor race... then we'll need to add one ourselves. I wouldn't know how to do that. Lucky for you (and me), SREP does have an unique race for that. Double click it to open it up.




Now you panick and scream and I'm joking.
We only want to mess with the 1st person animations, so that reduces our entries by... 1. Open up the one with the fewer keywords, those are the easiest. 




The GunBehavior.hkx is a Behavior Graph, it basically searches for the animations files (the .hkx files) inside the Animation Paths and uses them.

The Animation Paths are pretty much like a load order, but upside-down. It searches the 1st path for animations and applies them. If there are any missing animation files inside it, it tries to get it from the second, if said file is also missing from the 2nd, it tries to find it on the 3rd and so on and on... Until it has all the files that the Behavior Graph asked.

Target Keywords means that the animations inside the Animations Paths will be used on objects with that keyword. That's how the game knows how to differentiate a weapon from another, and which animations goes to which. Leave this window open for now and go to Part 5.




Part 5: B.A.E
Head over to your Data folder and find the mod's ba2 file. It's to spot it, it's named [plugin's name] - Main.ba2. If you don't find it, that either means the modder didn't archive the mod's files and they're loose, or you installed the mod incorrectly. Since you've been using the mod, that only leaves us with the former (unless the mod doesn't really depend on its Main ba2, but that's unlikely).

Open up B.A.E. and drag the Main.ba2 into it. Deselect the box from the Main.ba2 file and go into Main.ba2\meshes\[The first animation path], which is the path that has animations for Power Armor. If it doesn't have all the animations, it uses the ones from SREP. If it still doesn't have them all, it loads the vanilla ones. Checking the folder we have... WPNSprint.hkx.



But the problem I was having was with running with my weapon ready to fire, so it must be WPNRunForwardReady.hkx. We don't have that file here, so let's check inside the 2nd path. Oh, there it is, the last one. So, we need to modify a copy of it and place inside the 1st path. Select it and click extract. Extract it anywhere you want, you'll have all the previous folders that make the esp, which means you'll extract the WPNRunForwardReady.hkx file inside the directory "Meshes\Actors\Character\_1stPerson\Animations\SREP\". All the other folders will be empty, except the SREP, which will contain the file we extracted. That's good.

We know that the animation path for Power Armor is "[all those folders]\SREP\_PowerArmor", so we just have to put the file we'll modify there, and copy the Meshes folder into our Data folder, which will then merge and fix our issue. Also, don't move the hkx file from the folder it's in. It'll make things difficult for you.



Alright, that's cool, but what if the race thingy doesn't have an unique Power Armor directory? Well, we'll make one! Go back to the CK, write down every single target keywords present here and close the Creation Kit. Don't lose those keywords. If, for some reason, CK asks to save changes or something, don't. Just exit without saving.

Part 6: Making our own directory - You only need to do this if the mod you're fixing doesn't have an unique folder for PA animations. If it already does, skip to Part 7 (Don't actually skip part 6. Jolyne is a good JoJo and the setting is cool)
I'm gonna pretend SREP doesn't have its unique Power Armor folder for the purposes of part 6.

Open Fo4Edit and do the same as before, keep your load order intact. Press ok. Head into the plugin, go into Race, right click the Power Armor race, and "Copy as override into..." Go to the bottom and select <new file>.esp, but make sure it's flagged as an ESL.





Open up the race record you just created (it's inside your bolded custom plugin). Type Subgraph Data into the Filter by Name field. See all these Data #n records? Check their Target Keywords. It matches! Hm... but that's not the right record. Checking the perspective, under Data #0\SRAF - Flags, we see that this is 3rd person, so we'll ignore this one.

Data #1 matches all our keywords, and it's 1st person too! So this must be the right one! Go into Data #1, right click in the empty spot for Animation Paths, and click Add.


 After this, copy the top path inside this record, head to the new empty record you just created, at the bottom of the paths. Right click it, press Edit, then paste the same path, add a backslash and something like PA, or PowerArmor or something.


After this is done, right click this record you edited and move to the top of the order.


Save your plugin. If everything goes according to plan, any animation inside that folder you pointed at will load before any other animations.

Now for the fun part.

Part 7: Editing the animations

No, we are not going to literally edit them, just their timing. For this, we'll need to convert that hkx file into something we can read. Copy hkxpack-cli.jar and paste it into the folder that has the hkx file. Open Cmd, navigate to this folder and run the command java -jar hkxpack-cli.jar unpack [file name here].hkx.
After the process is done, you'll meet a .xml file. Don't close the Cmd window. Open the xml with an text editor (cough Notepad++ cough) and mess around with these "time" parameters.

The difference between footright and footleft is the difference between each step you make in game. If I had to guess, I'd say 0.0 to 1.0 is 1 second. Anyway, if it's too fast, try a difference of 0.5 between each step. Do mind that the duration goes higher than this 0.5 difference.

The duration is more or less like this: The value from 0 to 0.23 is 0.23, the difference between each step is 0.47 and the last step is at 0.74, so...
0.74 + 0.47 - 0.23 equals 0.98, which should be the duration*. Why? Because it will take 0.24 from the SyncLeft to the end, and 0.23 for the first step, which makes it a difference of 0.47 between the last and first step. I'm not totally sure I should treat SyncLeft as the last step instead of footleft, but it is what it is.



* the duration is wrong here because this is a screenshot from yesterday and I'm lazy

Save this thing and close your text editor. Delete the .hkx file and run the command java -jar hkxpack-cli.jar pack [file name here].xml. This will pack your xml into a hkx again. Now you can just put this file inside the folder you put as the first animation path back in Part 6. Btw, JoJo Part 6 is getting animated! Anyway.
In this case, the path is a subfolder inside the folder where we already are in. Put it inside the folder we want, go back to the directory before the meshes folder and leave this window here for now.

Go into your Fallout 4 Data folder, find your custom esp, cut it and paste it together with meshes folder. Your main folder will look like this:


And the folder your .hkx files are should look something like this:


Zip your main folder and install it as if it was a manually downloaded mod into your mod manager. Activate the plugin. Test. Yay! Now you can revert back to your old save or character and be happy! Or not. Maybe the footsteps are still a little bit off, or they didn't change at all. Oh well, in this case, keep on trying! Or just ask me to do it, I'll see if I can do something for ya.

Remember, I only walked you through one file. You'll need to do this to a lot of other animation files and weapon keywords. Don't worry about some keywords, they sometimes are just for weapon reloads, which don't mess with your footsteps. Different grips usually tend to mess up your footsteps though, so... Good luck!

----------------------------------------------------------------------------------------------------------

Which animation file is which:
  • Walking: WPNWalkForwardReady
  • Running: WPNRunForwardReady
  • Sprinting: WPNSprint
  • Walking while aiming: WPNWalkForwardSighted
  • Walking with the weapon lowered: WPNRunGunDown

Tools used:
B.A.E - Bethesda Archive Extractor
HKXPack (Beta 0.1.6) - We'll need Java for this to work
Fallout 4's Creation Kit 
Fo4Edit
Notepad++

Note that this process can be applied to any weapon mod that has this problem present, but most mods will differ from one another. I don't know the extent of what you can do messing with the animations, but it's not something I'd suggest you to do unless you have backups. I'm not responsible for anything bad that may happen to you while you're messing with the game.

Article information

Added on

Edited on

Written by

PhantomKnowledge

0 comments

  翻译: