Jump to content

Simple Q about identifying precombined meshes


kevkiev

Recommended Posts

So I figured that those ridiculous stairs by the guard post at Outpost Zimonja, as well as most of that prebuilt shack, had to be part of a precombined mesh. Otherwise Bethesda woulda just made them scrappable. But I looked in the CK and all those objects appear to be their own singular mesh. I.E. when I go to edit the base object, I can see that the .nif is, in the case of the ridiculous stairs, simply "meshes\architecture\shackstairs01.nif" (something like that anyways) and there's no indication of being part of a larger mesh. Same goes for the various parts of the unscrappable shack.

 

On the Precombined References page of the Creation Kit wiki, it mentions that precombines look something like Meshes\PreCombined\0000DBBB_01B8656E_OC.NIF.

 

Based simply on that, am I correct in thinking the unscrappable stairs and shack are safe to delete (or make scrappable) without worrying about the whole precombines/previs scene? Or am I missing something. I mean, it seems obvious, but I'm kinda stumped that Bethesda leave such an annoyance for no good reason. (Though I know it wouldn't be the first time.)

Link to comment
Share on other sites

The CK doesn't display any form of precombined data, nor does it display items in a cell as such in the render window. The precombined data is only visible in xEdit. Open the cell in xEdit and look at the XCRI records. That's where you'll find what precombines are in the cell and what static refs are part of which precombine. For Outpost Zimonja (RelayOutpostZimoinja) xEdit shows a ShackStairs01 static ref part of Precombined\0000DCEC_ABEA5372_OC.nif.

 

Look through the refs for the cell. Any ref that is part of a precombine will show as [Placed Object]. Look for that ref in the XCRI data and you can see what else is part of the same precombine. Since those stairs are part of a precombine, if you make any changes to that stair ref you'll be disabling the optimization for that cell.

 

EDIT: There may (or may not) be an xEdit script to search for a specific ref to see if it's part of a precombine. Someone more familiar with xEdit scripts might be able to chime in and confirm if any such script exists.

Link to comment
Share on other sites

Well, dang. Thanks for the incredibly inconvenient info. :tongue:

 

Kidding aside, I really appreciate your response. Yikes, really kind of an eye opener. I was intending to do just a bit of cleanup but, damn, soooo many crappy little things are part of larger precombines. Even doing some minor terraforming to clean up some of the dead shrubs that annoyingly stick up through crafted wood floors would break a bunch of precombines.

 

And it looks like the shack stairs I mentioned share a .nif with some brambles and other little annoyances (like creosote, whatever that is in the game). The stairs you saw are the ones by the brick building, and appear to be part of same nif for the bridge supports and... well, honestly, my eyes were glazing over at that point. A script like the kind you mentioned would be a godsend.

 

Couple Q's:

 

1. Would I be able to get away with deleting all components of a, and therefore the entire, precomined mesh? I.E. in the sense that maybe you can't break something that's deleted completely. I'd have to test it out in game but, yeah, it seems like the worst offending of the 2 sets of stairs (the one by the guardpost) might just be linked to various crappy items that I don't think would be missed. Although I'm thinking maybe I'd still have to regenerate PreVis. (That just came to mind, I'm already stretching my knowledge of the topic...)

 

2. In absence of an xedit script, I imagine it would be possible to extract the precombined meshes from the game archive and load 'em up in nifskope to at least get an eyeball of what all is in a particular precombine. Although I guess the usefulness of that would vary case by case.

 

and 3. What's XCRI? I didn't see that in the xEdit record. For the info I mentioned above, I just looked at the FormID portion of each item's Record Header.

 

Thanks again.

Link to comment
Share on other sites

1. That's not how this works. Any change to a precombine will be recorded in your plugin (PCMB timestamp) when you save it. "Deleting a precombine" means deleting all the refs in it. The game will detect the missing precombine data (and updated timestamp) on cell load and disable the optimization for the cell.

 

2. Not really sure what you would gain by that, but I think I recall reading (in the optimization system thread) that the newest version of Nifskope was able to load and render precombines. It was an issue in earlier versions.

 

3. XCRI data is in the cell record header:

E6k995X.jpg

 

It seems like you may be over thinking this. Why not just make your changes, regenerate and call it done? :wink:

 

EDIT: Some info on the timestamps, why they are important for this goofy stuff and how they can ruin your day.

Link to comment
Share on other sites

1. Ah, that's good to know.

 

2. And again.

 

3. Oh man, I totally missed that.

 

And... yeah, point taken. I sometimes get muddled in the details when learning stuff. I have a video of yours where you addressed the precombine/previs issues in Tales from the Commonwealth. Definitely something I can handle.

 

Thanks a ton!

Link to comment
Share on other sites

Easiest way to tell if a given placed object (REFR record) is part of a precombined mesh: search for the reference ID in FO4Edit (generically referred to as xEdit). In the navigation window on the left, each placed reference will have the words "Placed Object" next to them. If it has brackets: [Placed Object], then that means it is part of a precombined mesh. The "FormID" summary subrecord in the file header of a REFR record will also list the exact .nif it is in.

 

There is indeed a wonderful script for looking at precombineds in xEdit, made by the wonderful zilav with input/feature direction from me: https://www.nexusmods.com/fallout4/mods/23967. But as RedRocketTV mentioned, it is best to just regenerate precombineds and previs 999 times out of 1000. The script was mainly developed for two reasons: to allow me to play around with the precombined system and figure out how things work, and to use the "Clean Precombineds" feature to reduce uploaded mod size by getting rid of duplicates (ITM precombined .nif files, basically). It can massively reduce file size in some cases. For Scrap Everything, it cut the number of meshes needed from 1560 to 155, and file size form 200MB to 28MB. It probably won't be as extreme most places, since I only touched things within the vanilla settlement bounds in that cell, but it can still make a difference. Just make sure to backup the CK-generated precombined folder before running the cleaning .bat file, just in case :D.

 

The only problem is, if two mods regenerate precombineds for the same cell and different existing precombineds are left in by the script, things get funky. It is not a common problem (most people just don't bother/know how), but I have run into it with my mod (Scrap Everything) so thought I'd mention it. I have also have a tiny percentage of people for whom the resulting cell causes crashes, but even providing a non-trimmed set of precombineds didn't fix it, so I am pretty sure they just have something broken with their game files (or have another mod they aren't mentioning that breaks things).

Link to comment
Share on other sites

Thanks Vlits, much appreciated. Definitely going to be looking into that script mod you linked. The clean precombined function looks very handy, even if I don't take advantage of all its other functionalities (simple as running a bat file - I like the sounds of that!).

Link to comment
Share on other sites

kevkiev: regenerating might seem daunting at first, but it's really not that bad...more annoying that you have to do it at all than anything else. :laugh:

I'm glad VIitS mentioned that script...I'd forgotten about it being discussed in the FO4 optimization thread a long while back. If you haven't read through that thread yet, I highly recommend it. Loads of great info there!

Link to comment
Share on other sites

Yeah, your video looks pretty easy to follow. Really nice tutorial. My biggest concern right now is my plan of combining/ optimizing a mod that renovates Sanctuary, including a new bridge, and a Red Rocket mod that I've used and really like (the author warns of possible overlap with Sanctuary mods). I know the RR mod doesn't address previs/precombines and am 99.9% sure the Sanctuary one doesn't either (I haven't installed that one yet). Save an esp slot and ensure compatible optimization at the same time. And my concern isn't really a technical one, or even the tedium of covering such a big area, it's simply praying that the CK doesn't blow up during such a long process.

 

It's that plan that really came to mind when I looked at the script Vlits mentioned. I'd wager at least it's ability to clean out extraneous files after optimizing would be a godsend for my Sanctuary/RR project. As I get more comfortable with things, maybe I'll look into its other features too.

 

Ha ha, this game... so much energy goes to modding. I actually haven't got back into FO4 yet, but am already planning out a bunch of tweaks I wanna do. :D I'll probably tackle settlement and other worldspace tweaking (e.g. TFTC) as I encounter them in-game. Which, alas, means the big job I mentioned would be first up.

Link to comment
Share on other sites

  • 3 weeks later...

Wow, thanks a lot for this thread. A really interesting read. I'm working on my own worldspace at the moment and I was asking myself how I can optimize performance because I've a few areas, especially urban cells, that contain a lot of objects. So I assume that the best way would be to generate precombined meshes for all of my cells, right?

Link to comment
Share on other sites

  • Recently Browsing   0 members

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