Jump to content

New to Modding. File structure and dependencies


Jedlock01

Recommended Posts

I'd like to enter the modiverse and to start out I like to to get some insight in to file dependencies...for example I have a download and installed a mod that I'd to alter. the mod installed a a ba2, pex and psc file. I can't edit the pex files only view, I've unpacked the the ba2 file and tried to edit the psc files, but I don't get the file ,dependence.

 

Do I exact the file from the ba2 then edit then repackage and how to I do that?

 

Basically I don't understand what the the pex file is and how it works with the a ba2 and psc script? In short I'm lost......do I edit the script or the esp or the pex file? ...grrr

 

and I can't get notepad++ to work either. tried this edit...still doesn't get file path

 

cd %2
"%~dp0PapyrusCompiler" %1 -f="TESV_Papyrus_Flags.flg" -i="%~dp0..\Data\Scripts\Source" -o="%~dp0..\Data\Scripts"
pause

 

 

HELP!!!!!!

Link to comment
Share on other sites

It's rather simple.

 

A .BA2 file is an archive (similar to a zip file). It contains all files (meshes, textures, scripts, voice, animations, ...) required by the mod, except the esp / esm file.

 

A .PSC file is the source code of a script. If a mod author adds a script to the game, they'll create a psc file and add their code to it. However, these psc files are not required for the game. Because:

 

A .PEX file is a compiled psc file. Basically it works like this: If you have written your script you need to compile that script. The compiler creates a pex file that contains the information of your psc file and some other important information. The game will only access the pex file and not the psc file.

 

Most mod authors don't include the psc file. They are a) not important for the game and b) contain the source code of a script that some authors are not willing to share.

 

In a nutshell: If a mod doesn't include the psc files, you can't alter the scripts - period. There are some programs that can decompile a pex file but you'll never end up with the original source code. If a mod does include the psc files you have to edit them and then compile them again to get the updated pex file.

 

 

If you want to learn how bethesda plugins / mods work, I suggest starting at the very beginning and not pick a topic of chapter 2 or 3. Search for a tutorial on yt (there are plenty).

Edited by Crosstieger
Link to comment
Share on other sites

I use the included papyrus compiler that runs through the command prompt shell (i started learning coding on linux command prompts, so it’s a bit natural to me). All you have to do is edit the.bat files to point to the correct source files from Bethesda (data\script\source). If they’re not unpacked, unpack the zip that the CK installs (all of mine were unpacked).

 

As far as modifying the original code files for the mod, if you recompile the psc with your alterations and the mod came as a ba2 file, you’ll need to attach your altered script (and I highly suggest naming the pex differently for your sanity). This method is what i do with esm files, and it should work with esp files (when they get rearchived, the old and new pex shous be in the ba2)

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...