Jump to content
Arthmoor

[Skyrim SE] Porting a mod from LE to SSE

Recommended Posts

Many fine mods have been created for the Skyrim Legendary Edition (aka Classic) over the years and not all of them have been brought over to the Special Edition. Due to differences between LE and SE, they can't simply be dropped in. They must be properly converted over so that they will function correctly in SSE and not lead to save corruption or CTDs. The following rough outline of the process should be enough to guide you through porting your mod over to SSE. This guide is intended for mod authors to use as this process is not suited for end users to follow due to the details that need to be addressed to do the work properly. It also assumes a certain level of familiarity with the packaging of files relating to the mod.

You'll need to have access to the current SSE CK and a copy of xEdit 4.0.1 or higher at minimum. If you have meshes, you'll need a copy of the SSE Nif Optimizer program.

BSA Files
 
If your mod uses a BSA file (and pretty much any decent one ought to be if it has assets to provide), you can't simply use that file with SSE. The game will either hang or crash at the opening menu.

This step should be done before trying to load your mod into the CK as well since the same problems will occur with the CK - it'll either hang or crash.

Meshes (.nif files)

Unpack your files to a temporary location somewhere. Grab Nif Optimizer and follow its instructions to convert your files. If you have any files that use decal flags (the SLSF1_Decal or SLSF1_Dynamic_Decal flags) these flags may need to be removed. If you some across one of your files that has translucent parts that shouldn't, this is probably why. SSE seems to handle those flags differently and plenty of vanilla stuff had to have this done as well.

Textures

.tga files are no longer supported. If you have assets using these, they need to be converted into proper DDS files.

Textures originally saved in either the A1R5G5B5 format or the B5G6R5 format must be resaved in A8R8G8B8, R8G8B8, or an equivalent compressed format like DXT5 or DXT1. If this is not done, some installations of DirectX 11 will not be able to process it and SSE will crash. This seems to be most common for folks using Windows 7. SSE Nif Optimizer should be able to detect these issues with the "Scan Textures" option.

Some landscape textures will need to be fixed manually. If your landscape texture loads into SSE and looks like it's wet when it's not supposed to be, you found one that needs to be fixed.

Animations

Animation files for 32 bit will not work out of the box. Depending on what they are, you may end up with NPCs or the player stuck in a default pose unable to move, or perhaps even being unable to move the camera at all. Fortunately Bethesda has supplied a tool with the new CK that will allow you to update your .hkx files to the new format. This is necessary due to Havok being upgraded to 64 bits.

The ESP/ESM File + Facegen

Your plugin file needs to be loaded into the new CK for SSE and saved so that all of the form versions on the records can be properly updated.

If it's an .esm file then you need to remove that flag to be able to load it properly to be resaved.

You should make sure you include Update.esm, Dawnguard.esm, Hearthfires.esm, and Dragonborn.esm as masters to your file. There should be no exceptions to this as all SSE users will be playing with these files active. The game will not even launch if one is missing.

If your mod has NPCs, this process will also generate updated Facegen files. Be aware that if you have made facegen changes to vanilla NPCs those new facegen files will have been saved in the folder for your mod and you'll either need to separate them to the correct folders or delete what the CK generated when it saved and use the manual process with CTRL+F4 to generate them again. The manual process will assign them to the correct folders.

You can safely delete the .tga files generated by the CK. The game will never use them and they just waste space in your mod's archive for distribution.

DO NOT attempt to circumvent the need to load your mod into the CK by using scripts or other tools to shortcut the process by faking the new form versions. You WILL end up corrupting the saves of anyone who uses your mod if you do this.

Fixing Up the ESP/ESM

Once your file has been saved you'll need to do some minor fixing to make sure it's fully ready.

River Flow/Water Data

Mods which edit exterior CELL records will need to be checked cell by cell to update the water data to fit with the new shader based water flow mechanics introduced with SSE. This is best accomplished by using xEdit to compare your CELL data with the CELL data from Update.esm. In nearly all cases you should forward the changes from Update.esm because Bethesda themselves didn't do so in their own DLCs which overwrite that. Guess who had to fix that :P You can also use USSEP as a guide for the proper value since we've already gone through and corrected them all for the base setup.

Failing to account for this information will lead to people complaining about water seams on the cell borders between your work and the base game and will also show up with water flowing the wrong way as well.

New Ground Clutter

There was a lot of new foliage and other ground clutter added to places all over the game. Especially in more populated areas like the towns and villages. You will need to check to be sure you have no conflicting placements with these new objects. Assuming you know your mod well (and who doesn't) it shouldn't take more than a couple of minutes to poke around any work you've done and make sure no new stuff is in your way.

Failing to address this will result in some unsightly clipping in many places.

Landscape Data

In several instances, landscape was also edited to add more ground details such as grass and those tiny rocks. Old mods will not have this underlying data if they've edited the landscape as well and it will probably be worth redoing much of that in order to preserve continuity with any surrounding cells that have not been edited. It may be possible to use xEdit to copy the Vertex Normals and Alpha Layer data so long as the land height itself hasn't been edited, but in doing so the mod will need to be rechecked to make sure no grass is poking through in places it isn't wanted.

Worldspace and CELL Editor IDs

If you have worldspace or CELL records with underscores in their editor IDs, you will need to manually change those to remove the underscore. If you do not, it will cause SSE's save sorting to be unable to handle the situation when you save your game in one of these places. This results in a player's saves no longer being listed under their character names which will make them harder to locate and could lead to corruption as well.

Weather Data

All of the default weather now supports Volumetric Lighting and has a new set of records to facilitate this. If your mod changes weather data it will need to account for this.

Other Changes To Be Aware Of

All of the game's grass records (GRAS) have been updated to push higher grass density.

Most of the game's Image Space Adapters (IMAD) have been updated with new alpha and blur values.

Most of the game's Image Spaces (IMGS) relating to weather have been updated with new HDR values.

A few Landscape Textures (LTEX) picked up an unknown INAM value, along with a couple having specular values modified.

Many snow and ice related statics (STAT) have been updated with new texture sets and material shader settings.

5 new landscape texture sets were added. Referenced by many of the other edits.

Pretty much every type of water (WATR) was updated for the new water shaders.

Books can no longer use the hidden Note/Scroll flag. Any changes to this will be automatically reverted by the CK every time. The game no longer uses them either.

ESLify Me?

If your mod happens to be small enough to qualify, you may wish to consider marking it with the ESL flag. Doing so can help extend the number of slots a user has available for other mods.

Consider the points raised in this topic before you decide: https://www.afkmods.com/index.php?/topic/5079-plugin-files-and-you-esmeslesp/

LOD Files

LOD files for objects will need to be regenerated as they are using a different texture atlas layout than the one supplied by LE.

LOD files for trees should be useable as-is, and this is recommended since the SSE CK cannot generate trees. In my experience, xLODGen doesn't do the job correctly either and results in tree LOD that doesn't match the actual trees.

Scripts

Scripts do not need to be recompiled. Despite rumors that they will break, this is not the case even for things that relied on SKSE. All vanilla and DLC Papyrus .pex files work out of the box, as do all SKSE script when being used with SKSE64. You should have no reason to need to recompile any of your own .pex files when porting to SSE.

That doesn't mean you're home free though - you may have a special situation with a Papyrus script written to work with a specialty SKSE64 plugin that needs to be recompiled to work. You'll have to check with that plugin's author to find out if that needs to be done.

In my personal experience, all of my scripts for all of my mods worked right out of the box. This includes all of the MCM related scripts that began working as though nothing was wrong when SKSE64 finally came out.

One thing you do need to keep in mind though is that the CK's default folder for scripts has changed. Instead of being stored under Data\Scripts, they will now show up under Data\Source. There are 2 solutions to this issue:

1. Leave this as it is and copy all of your own scripts to match the new path names.

2. Change the location in your CreationKitCustom.ini file to point to the old one. The line should look like this: sScriptSourceFolder = ".\Data\Scripts\Source"

Whichever solution you choose you need to be sure that all vanilla and DLC scripts are in that location or the CK will not be able to find them.

Sound/Voice/Video Files

Sound effect files do not require conversion. They can be used as-is.

The same is true of any recorded dialogue. Those work as-is.

Video files do not need to be converted either. They should all run as-is.

SKSE DLL Files

These must be recompiled to use SKSE64 or the plugins will simply not function. If your mod depends on one of these, the plugin's author needs to do the work and release an update.

Share this post


Link to post
Share on other sites

​Thanks for compiling the list Arthmoor. You mostly talk about forward compatibility. But what about backwards compatibility? Will, say, a bsa packed for SE work for the 32bit version? I.e. will we, once we do properly migrate as you outlined, be able to serve both versions with the new bsa, or would we have to maintain two separate mods?

Share this post


Link to post
Share on other sites

No. There is no backward compatibility at all because the formats on these things are different. Also I need to add some more stuff to the list cause I forgot about them :P

Share this post


Link to post
Share on other sites

Lol you've probably, one week before release, already forgotten more things than i will ever know about SE modding :D

 

Thanks for the answer. Guess it's time to give a last hard look at my vanilla Skyrim mods to see if they are in a state they can be abandoned, moving forward to the SE.

Share this post


Link to post
Share on other sites

The water edits are the big thing right now. There's a lot, cause any incidental cell edit will include that data and LOTS of stuff was near water, and some of it was directly addressing old water flow that was bad. It's not really feasible to throw USLEEP into the SSE CK and start hunting by hand either. So we're waiting on xEdit support for that.

 

This will in turn delay anything that depends on USLEEP, like Cutting Room Floor.

Share this post


Link to post
Share on other sites

I hope this SSE is worth the trouble to get mods up and going with it. It sounds like a lot of work so far that I don't want to do myself :P

 

I think I'm going to wait and see for it to mature before I dive in myself.

Share this post


Link to post
Share on other sites

Very useful.  Thanks for posting this Arthmoor. :)

 

Although, for the moment only the last section applies for my mod and if I got it right I only need to load my mod into the new CK then re-save it.

 

Of course I need to clean it in TES5Edit a *final* time, unless I'm updating my mod, before I've completely converted my mod into a SSE mod.  Btw...  Can TES5Edit handle SSE mods properly from the day the new CK is available?

Share this post


Link to post
Share on other sites

xEdit hasn't bee updated yet. I'm not sure what their schedule is for doing so, but I am hoping it's ready to roll before the 28th so we can use it to get USLEEP updated.

Share this post


Link to post
Share on other sites

I think that is a little too optimistic to expect an updated TES5Edit to work with SSE mods the 28th.  I would be more than satisfied if zilav or who ever updated TES5Edit for SSE mods the 29th or a week later perhaps two weeks.

Share this post


Link to post
Share on other sites

 

Water and Flow Data

There are numerous instances throughout the game that have been updated to take advantage of the new water flow mechanics that were introduced. So far as I can see, every river has had the flow type changed and new drop in icons have been placed to indicate the direction the water should go. In some cases the type of water has also been changed. Mods which edit cells with water in them will need to update this data or they're going to cause noticeable patches of rivers, lakes, and even the ocean that don't look right or flow properly with the surrounding cells. Yes, Bethesda themselves forgot to account for this in their DLCs too so guess who's going to have to fix that now :P

 

 

:facepalm: .. though coming from Bethesda its not surprising

 

Very pleased the water upgrade was not just a case of shader / effects, but does actually address the flow direction aswell, that was my biggest immersion killer in the original. Not so good for the USLEEP update, but by the nine its going to be nice not looking at water going into the side of river banks

 

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

 

One question reference Textures - Did they not update the way they pack them into BA2s' ? ( same as they did for FO4 in that the highest resolution top layer mipmap is packed as a separate file, then the game only loads the big one on the rare occasions it is needed = more optimal loading / caching )

 

I know I will need to redo my Vanilla Reduced Textures BSAs and dummy plugins anyway ( well, that is if there is a need for VRT for SE, I need to give that some thought really ), but I would be surprised if the textures were not part of the optimisations made to SE

 

 

Edit : Oooh and, Arthmoor is there any need to update your guide on using the official Archiver, or is it pretty much the same still ?

Share this post


Link to post
Share on other sites

They're not using BA2 for SSE. It's still BSA but with LZ4 compression instead, and something else about the headers for non-compressed files that the existing tools don't know how to handle. Textures are still standard dds files. They aren't using the new BC7 compression in SSE.

 

The official archiver works exactly the same as the old one. You just need to make sure you're using the right one because the program doesn't even tell you.

Share this post


Link to post
Share on other sites

No. There is no backward compatibility at all because the formats on these things are different.

 

Oh god you just saved me from a very big mistake. :D

 

 

Uploaded new xEdit build with SSE support.

That's what they call dropping the mic. :)

Share this post


Link to post
Share on other sites

one question regarding updated meshes:

Did bethesda update all their vanilla meshes themselves? or does the engine still handle old meshes?

Since you mentioned most meshes of USLEEP work, but only a handful needed upgrading, is there something to look out for, to spot which meshes need an upgrade (aside from going in-game and see if i encounter crashes)?

Share this post


Link to post
Share on other sites

Jon could answer that better than I can. I'm not actually sure what all they did to their meshes, but the only one in USLEEP to complain so far was a horker mesh we removed a null bone from. We won't be including it with the SSE archive.

Share this post


Link to post
Share on other sites

Question: there's a rumour on Reddit that cell data has changed so cell modifications are not compatible and will need to be redone. What is this about, and is it something one could just fix in the CK/xEdit or does it mean that existing cell modifications are broken/gone and need to be redone from scratch?

Share this post


Link to post
Share on other sites

One question which isn't answered here is.. how are we supposed to port a mod that requires USLEEP as a master? Will the switch masters xEdit script work?

Share this post


Link to post
Share on other sites

one question regarding updated meshes:

Did bethesda update all their vanilla meshes themselves? or does the engine still handle old meshes?

 

It handles old meshes, but seems to be a bit more picky about them being well-formed.  Also certain texture formats are no longer supported like uncompressed grayscale, which the game reads as if it were RGB with only the red filled out.

 

With that said every single NIF file has been run through their internal converter program to have a better vertex data layout, which enables the engine to more optimally read all the data into DX11. Not to mention it's significantly compressed, where a typical vertex (position, UVs, normals, tangents, bitangents, and vertex colors) goes from 60 bytes to 32 bytes.**

 

The vertex format is the exact same as FO4's except SSE meshes are never half-precision (using 16-bit half floats for all of the vertices). Most all blocks are completely identical,  but no existing tools will even be able to open the NIFs without an update even if they can read FO4 NIFs, since SSE NIFs are a bit of a mixture.  The NIF file versions go 83 -> 100 -> 130 for Skyrim -> SSE -> FO4, showing that SSE came between the two developmentally (which we already knew).

 

 

** Which, if they're doing it correctly, the engine is having to take a bit of extra time to load the old 60 byte vertex, but it's getting converted to the new format before being sent to DX11.  So if there is any kind of overhead with old meshes it should only affect loading time.

Share this post


Link to post
Share on other sites

Thanks for the explanation. So that means i should expect my old meshes to work, if they adhere to Skyrim's standard.

That internal converter program you mentioned, i suppose that means it will not be publicly available, right?

Is a conversion functionality planned from the community (e.g. nifscope?)

Is there a tool to check meshes for errors, that could cause issues? I have hundreds of meshes, mostly old armors and weapons from unsupported mods in my load order, and have invested countless hours keeping the associated merged esp error free and up to date. I see no way of doing the same manually for all meshes, and would hate to let that work all go. I'd be fine dropping parts of it, if there was an automated way that told me where the black sheeps are hiding. Just a bit of background, why such a tool would help me massively.

 

Since team USLEEP managed to find that rotten horker mesh so quickly, i was hoping there is in fact an automation tool...

Share this post


Link to post
Share on other sites

Question: there's a rumour on Reddit that cell data has changed so cell modifications are not compatible and will need to be redone. What is this about, and is it something one could just fix in the CK/xEdit or does it mean that existing cell modifications are broken/gone and need to be redone from scratch?

It's just a rumor. An unfounded one. Old ESP files will work, but you should still resave them so that it triggers whatever internal updates they've done to take place, such as updating NPC facegen. The only thing you're going to have to check for manually afterward are cells with water data in them as explained in the OP.

 

One question which isn't answered here is.. how are we supposed to port a mod that requires USLEEP as a master? Will the switch masters xEdit script work?

You can use SSEEdit to change the master file in the header. Normally that's something we all strongly recommend against, but in USLEEP's case since the filename is all that's changing for SSE, swapping the master won't damage the form IDs.

 

That new file name will be "Unofficial Skyrim Special Edition Patch.esp" btw.

 

 

Since team USLEEP managed to find that rotten horker mesh so quickly, i was hoping there is in fact an automation tool...

That Horker literally announced itself as a missing mesh icon, it wasn't hard to spot while out wandering around :P

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Support us on Patreon!

×
×
  • Create New...