The forum has been set to read-only mode. For community discussion and questions, head over to our Discord: https://discord.gg/taleoftwowastelands

Create your own csv for use with the conversion script

General modding guides and authoring tutorials.
Post Reply
User avatar
RoyBatty
Gary
Posts: 7742
Joined: Sun Apr 27, 2014 10:26 am
Location: Vault 108

Create your own csv for use with the conversion script

Post by RoyBatty » Sat Jul 11, 2020 10:48 am

We talked a bit about this on the discord, about making your own csv for use with the conversion script to replace any forms you like with another. We use this a lot to change forms which reference the Fallout3.esm to ones which reference FalloutNV.esm or one of the DLC esms. We also use it replace things like books with magazines in converted mods, or to change static plants into the pickable ones. So I'll use this last thing as an example on how to make your own.

First we'll credit our own JaxFirehart for creating this format and for coding the original conversion script. Then we must credit zilav for rewriting that script to not only make it faster and work with newer versions xEdit but also making it so you can select from a limitless number of csv databases.

Now the tutorial.

The csv is a simple text file with comma delimited fields in the following format, which is always at the top of every new csv you make. Don't forget to copy paste that and put it in any new csv you make.

Code: Select all

Type,Old Master,Old FormID,Old EID,New EID,New Master,New FormID
This format is super simple, and mostly self explanatory but I will outline exactly what each field is.

Code: Select all

Type = This is the form type for the original form you want to change, in xEdit this is always a 4 character assignment. Each form type you can find on your own and they are listed in xEdit itself in the filter editor or by looking the record header for the form. You would do well to get familiar with them in general.

Old Master = the name of the master file the original record is either in or referencing. You can change both references and base forms with the script. Be careful when changing base forms, this is really only for our use, but you can use it too if you are an advanced level author and need to do such things.

Old FormID = The original formid of the form you are changing, with the load order removed, so it is truncated to only 6 digits and always preceded by 0x

Old EID = The original Editor ID of the form you are changing.

New EID = The new Editor ID of the form you are changing. References usually don't have an Editor ID, but sometimes they do if they are referenced via script. Most of the time you don't want to change those. If it's a base form and it has the same name as another base form, you may want to change it. Most of the time you don't unless it will create a duplicate of an existing Editor ID, in which case you will want to change it.

New Master = The name of the master you are changing the reference or base form to. This is mostly used for reference changes from one plugin to another.

New FormID = The new formid of the form you are changing, with the load order removed, so it is again, truncated to only 6 digits and always preceded by 0x
When creating new lines in the csv all fields are always required. Do not omit any.

Here's an example of changing the brain fungus in any plugin to the pickable version in TTW.

Code: Select all

STAT,FalloutNV.esm,0x02811A,WastelandFungusBrain01,TTWBrainFungusActivator,taleoftwowastelands.esm,0x01806A
The original TYPE is STAT , which is a STATIC. The original Master is FalloutNV.esm, the original formid is 0x02811A, the original EditorID for that base form is WastelandFungusBrain01, the new EditorID for that base form is TTWBrainFungusActivator, the new Master is taleoftwowastelands.esm, and the new formid for that form is 0x01806A

This may be confusing to you but let me explain. When you run the script on a plugin in which the forms in the csv DO NOT EXIST the script will look for REFERENCES which contain those forms and change them accordingly. This is very important to remember! If you were to run this script on a plugin in which the ORIGINAL form is in that master, it will change that BASE form to the new one. You must be careful with that and you should be very aware of what you are doing if you choose to do that. The script is very powerful and there are no safeties as it was originally made for our internal use.

So there you have it, happy modding!

-TTW Team
Image

User avatar
jlf65
Posts: 1535
Joined: Wed Aug 10, 2016 9:10 pm

Re: Create your own csv for use with the conversion script

Post by jlf65 » Sat Jul 11, 2020 7:11 pm

Wow! That is pretty powerful. Looks useful in mods that change large numbers of entries, like converting statics into misc items, for example. I've seen some authors of such mods complain about months spent changing entries, but a script could change them all in moments.

User avatar
RoyBatty
Gary
Posts: 7742
Joined: Sun Apr 27, 2014 10:26 am
Location: Vault 108

Re: Create your own csv for use with the conversion script

Post by RoyBatty » Sun Jul 12, 2020 4:55 am

Indeed, and that's exactly what we used it for. I use it also when I convert mods to add cooking fires, change plants to pickables, books to magazines, etc.
Image

Post Reply