Jump to content
Sign in to follow this  
asdasfa

RaceBodyMorph (NPC BodyMorph Randomizer) 1.0.2

Recommended Posts

View File

RaceBodyMorph (NPC BodyMorph Randomizer) (Could use a better name, but meh...)

 

A simple BodyMorph plugin that I originally made for myself causing me to learn scripting in GECK.

 

Description:
Allows randomization of NPC body morphs based on minimum and maximum values for each bones that can be set for each race and gender via the MCM.
Use Ctrl+M to quickly access the Activation Menu.

 

RBM01.jpg
RBM02.jpg
RBM03.jpg
RBM04.jpg

 

Requirements:
BodyMorph 1.1.0+, of course.
NVSE.
NVSE Extender (NX).
Mod Configuration Menu - Needed to activate and setup the plugin.
Weighted body, like T3F Body with BnB (look in Files section).
Weighted armors or clothing, like Bouncing Breasts Type 3 Armors.
Or T3FBBR BnB Body Replacer + Rough Outfit Conversions.

 

Notes:
There are alot of changes as of version 1.0.0 (January 3, 2016). To avoid issues from updating from an earlier version, it is advised to install it with a RaceBodyMorph-free save or better yet a BodyMorph-free save, to do so:
Disable/Uninstall BodyMorph and RaceBodyMorph from your load order, start game and save. Then install the latest version of BodyMorph and RaceBodyMorph.

 

Updating RaceBodyMorph or the core BodyMorph to a new version will deactivate the mod and reset all settings on load, so be sure to use the mod's Save/Load Settings function to save time.

 

Changelog:


- 1.0.2 (February 18, 2016)
Minor scanner tweaks and optimization.

 

- 1.0.1 (February 13, 2016)
Added 5 more settings, making a total of 10 settings.
Very minor fix in the Female Others preset.
Some internal MCM tweaks.

 

- 1.0.0 (January 3, 2016)
Increased required BodyMorph version to 1.1.0.
Rewritten code is more robust.
Each race per gender now has their own percentage weights on which settings will be used.
Use NX variables as flags instead of tokens. This completely frees the mod from the AddItem bug and equipment re-evaluation.
Dead Cleanup has been removed as it is now handled by the core.
Added Ctrl+M hotkey for quick access to Activation Menu.

 

- 090915
Merged both Female and Male settings into one MCM menu.
Now creates a settings ini in the Data/Config directory for editing slider limits to easily accommodate future changes to the core mod without updating.
Removed Parts settings.

 

- 080715
Added GetInSameCell check on the scanner instead of the previously removed GetInGrid.
Some minor script modifications.

 

- 080415
Removed GetInGrid check from the scanner.
Now uses a dummy armor for the AddItem bug workaround instead of leather armor that should prevent removal of NPCs' leather armor when resetted.

 

- 072015
Fixed dead cleanup not working.
Minor script modifications and optimizations.

 

- 071715
More foolproofing on the scanner.

 

- 071615
Minor modifications on the scanner.
Changed default scanner smoothness from 0.05 to 0.5.
Unsetted biped slots of tokens. Tokens shouldn't be equipped anymore.

 

- 071515
Rewritten and improved scanner script.

 

- 071215
Just minor logging changes.

 

- 070615
Added settings for toggling parts. (This will affect the Reset function, for example, disabling a part will prevent that part from being reset to 0)
Made the dead cleanup toggleable. (Default: Off)
Added 2 more slots for saving settings, making a total of 3 slots.

 

- 070415
Modified script for race determination. Will now check if a race name contains the name of a base race. For example, a custom race with the name "Custom Asian" will now be processed under the "Asian" category instead of "Others". This makes proper support for DLC races.

 

- 063015
Minor script changes.

 

- 062815
Added "Others" category for custom races.
Added settings for toggling races.
Added Save/Load Settings.
Refactored a lot of variables.
Replaced the misc token with an unplayable armor item to make it invisible from inventory.

 

- 062515
Added cleanup for bodymorph data of dead actors. This should keep the size of the nvse cosave file down.

 

- 062415
Finally fixed the unresponsive combat bug. It is caused by the AddItem function's bug that causes the weapons of the NPCs to become unusable.
Added some cleanup code.

 

- 062215
Will now ignore actors that are alerted, alarmed or in combat and actors that are within the same cell and are hostile towards the player.

 

- 032215
Reset function will now only reset actors that are enabled in the menu.
Fixed children not resetting. Forgot to remove a flag.

 

- 031915
Added Same Cell Scan.
Use ScaleUp and ScaleDown instead of ScaleAbs.
Forgot a bone in the reset script. Fixed.

 

- 031815
First release.

 


  • Submitter
  • Submitted
    03/17/2015
  • Category
  • Requires
    BodyMorph NVSE NX MCM

 

Share this post


Link to post

what would be sweet is if thimod could be made to do the same for SKyrim and such with there races you could let say Morph a Akaviri race and morph theme too look Asian. Be sweet as hell.

Share this post


Link to post

what would be sweet is if thimod could be made to do the same for SKyrim and such with there races you could let say Morph a Akaviri race and morph theme too look Asian. Be sweet as hell.

 

Yeah, that would be awesome.

Right now I'm using "EveryBody's Different Redone" to have body variations in Skyrim. Problem is it uses a lot of memory since you're adding more body type meshes and textures to it. Add a lot, and you'll be experiencing crashes frequently. And since it's not dynamic, a certain group of unnamed NPCs will always have the same body mesh.

 

I guess we'll just have to hope for Expired's BodyMorph for Skyrim and blabba's Project CITRUS.

Share this post


Link to post

Can I use it without those armors? I will still get all the changes when characters will be nude like in the sex scenes right?

 

Also I have Breeze male bodies now, but is this mod compatible with it?

 

For females I'm using Type 3 with T3F with BnB.

Share this post


Link to post

Right, you can use it without those armors, the replacers I listed are just the ones which I tested BodyMorph with.

For females, BnB bodies should work fine.

As for male bodies, I haven't tried other replacers yet, but as long as its properly weighted to the skeleton included in BodyMorph, you should be able to see the morphs.

Share this post


Link to post

Updated 062215

 

Will now ignore actors that are alerted, alarmed or in combat and actors that are within the same cell and are hostile towards the player.

 

This should reduce the instance of hostile npcs that are not attacking everytime you enter/scan a new cell. Assuming that those npcs are not yet touched by BodyMorph.

Share this post


Link to post

I thought the framework was already ignoring those who weren't morphed

Share this post


Link to post

I've taken a peek at BoMo's OkToMorph code and actors in combat are indeed ignored, however when entering new cells, hostile NPCs are not automatically in combat state, so they tend to playidle beforehand, preventing them from responsive combat.

This plugin's update checks if the player is enemy with the NPC's faction(potential hostility) to prevent them from being assigned by RaceBodyMorph for morphing.

Only NPC's within the same cell as the player are affected, farther hostile NPCs are assigned normally.

 

This is of course just a workaround and does not completely solves the issue. Entering a cell with hostile NPCs that already has the BoMo spell on them is a different story. Just for those who wants a playthrough with BoMo on and with responsive combat.

 

Tested inside Vault3. Outside Vault3(Vault3Exterior), one or two fiends that are on a different or farther cells still gets unresponsive.

Share this post


Link to post

I should modify that script with something I have in mind, but I'm just too busy in these weeks. I hope to manage soon.

Share this post


Link to post

Updated 062415

 

Figured out what's causing the unresponsive combat. Looks like the animation part has nothing to do with it.

It was the AddItem function's bug that's causing the NPCs' weapons to become invisible and unusable everytime a token is given to them!

http://geck.bethsoft.com/index.php?title=AddItem#Bugs

 

So that's why they're not attacking, they can't use their weapons!

There! Fixed!

Sheesh!

Share this post


Link to post

Token? I don't think BodyMorph core adds tokens :-O

Share this post


Link to post

Yeah adding Misc tokens is ok, but adding Armor tokens causes NPC's to re-evaluate their weapons and armor.

Share this post


Link to post

Token? I don't think BodyMorph core adds tokens :-O

 

Nope. But this plugin and your plugin does.

 

Yeah adding Misc tokens is ok, but adding Armor tokens causes NPC's to re-evaluate their weapons and armor.

 

Misc tokens is what I use though, so my case would be the target actor's weapon toggle between being visible and usable and being invisible and unusable.

Share this post


Link to post

 


Nope. But this plugin and your plugin does.

 

Mmmh I've put so little importance to my randomizer (it was only for my testing purposes), that I forgot that. Good discovery, I'm going to scratch that script one of these days.

 

 


Yeah adding Misc tokens is ok

Halstrom, in this case for example it seems giving issues with MISCs too :-/ I guess this thing should be tested well, it's important, due to the big quantity of mods with misc tokens.

Share this post


Link to post

Updated 062515

 

Added cleanup for bodymorph data of dead actors. This should keep the size of the nvse cosave file down.

Share this post


Link to post

Updated 062815

 

Added "Others" category for custom races.

Added settings for toggling races.

Added Save/Load Settings.

Refactored a lot of variables.

Replaced the misc token with an unplayable armor item to make it invisible from inventory.

 

Note:

A lot of changes with this one. To avoid issues, it is advised to install it with a RaceBodyMorph-free save or better yet a BodyMorph-free save, to do so:

Disable/Uninstall BodyMorph and RaceBodyMorph from your load order, start game and save. Then install the latest version of BodyMorph and RaceBodyMorph.

Share this post


Link to post

Updated 070415

 

Modified script for race determination. Will now check if a race name contains the name of a base race. For example, a custom race with the name "Custom Asian" will now be processed under the "Asian" category instead of "Others". This makes proper support for DLC races.

Share this post


Link to post

Updated 062515

 

Added cleanup for bodymorph data of dead actors. This should keep the size of the nvse cosave file down.

 

Does this function toggleable? Some mods gives possibility to reanimate/resurrect dead peoples, so for some users(like me) keeping morphs on npcs more important than few kilobytes.

Share this post


Link to post

At the moment, no. But I can easily make it toggleable on the next update, which shouldn't take long since I'm also planning to add toggles for body parts.

Though I think cleanup should be handled by the core mod itself but since it hasn't been updated yet, I decided to include it in this plugin, at least until the core mod includes that kind of feature.

Share this post


Link to post

Updated 070615

Added settings for toggling parts. (This will affect the Reset function, for example, disabling a part will prevent that part from being reset to 0)
Made the dead cleanup toggleable. (Default: Off)
Added 2 more slots for saving settings, making a total of 3 slots.

Just a note, I noticed that if I kill a bunch of morphed NPCs in a single cell without cleanup, I start to get constant stutters every second until I leave the cell with the corpses and the .nvse file size increases more than when they are alive. I thought it was some kind of bloat but the added size is just a hundred kb compared to the size of the .nvse file when those NPCs were alive, so it's probably not it.
So I looked at the core mod's script to find out what's going on. It's a constant stuttering, so it should be a running script, so I looked into "BoMoScannerQuestScript" and figured that the cause may have something to do with the core mod trying to cast a spell on dead actors, so I added a GetDead flag to prevent it from casting the spell on corpses and that seems to have fixed it, tested it repeatedly with and without the modification to the core mod. Though I'm still not that solid about this, so any reports are welcome.

Here's the part that I changed in BoMoScannerQuestScript, starting at around line 39:

if rTarget.GetDead == 0
   if eval(0 != call fnBoMoNXGetEVFl rTarget "BodyMorph::Version")
      if (0 == rTarget.IsSpellTarget aeBoMoRescale)
         rTarget.CIOS aeBoMoRescale
      endif
   endif
endif

So if you prefer to keep the cleanup off, it is advised to modify the core mod's script to avoid the stutterings.

Share this post


Link to post

Is it possible to adjust maximum size for part more than 6, or it is limited by the BodyMorph?

 

Also, your bodymorph token using a slot that some clothes uses(for example: some outfits from coito ergo sum, some outfits from kristinas closet), so, can you try to rearrange it? I hope there is still free slots number that unused by any clothing mods.

Share this post


Link to post

Asdasfa,

 

First, thank you, this is what I was looking for, diversity in the NPCs adds depth to the game.

 

I have a question, is there any documentation on what the different morph elements actually do and the range in actual size? (inches and or cm)

 

I ask so I could use the statistical data of various races to set the variables to be representative. There is more then enough Anthropometry data

available to set the ranges for a race to the 70 percent zone of the various samples.

 

Any help would be appreciated.

 

 

Share this post


Link to post

Is it possible to adjust maximum size for part more than 6, or it is limited by the BodyMorph?

 

Also, your bodymorph token using a slot that some clothes uses(for example: some outfits from coito ergo sum, some outfits from kristinas closet), so, can you try to rearrange it? I hope there is still free slots number that unused by any clothing mods.

 

It is indeed limited by BodyMorph.

Oh, alright. It doesn't really need to be equipped. I actually just set the biped slot to stop the GECK from throwing warnings, I'll just unset it from the slot. It should not be automatically equipped anymore. Will upload shortly.

 

Asdasfa,

 

First, thank you, this is what I was looking for, diversity in the NPCs adds depth to the game.

 

I have a question, is there any documentation on what the different morph elements actually do and the range in actual size? (inches and or cm)

 

I ask so I could use the statistical data of various races to set the variables to be representative. There is more then enough Anthropometry data

available to set the ranges for a race to the 70 percent zone of the various samples.

 

Any help would be appreciated.

 

I'm afraid there is no documentation about that as it is dependent on your body replacer and how it is weighted. You will have to test it yourself with the body replacer you're using.

Also, support for lower parts (Thighs, calves, feet) are removed from the latest version of BodyMorph as it messes up IK, so just leave the values at 0, 0. I just left it there just in case it comes back.

Share this post


Link to post
Updated 071615

 

Minor modifications on the scanner.

Changed default scanner smoothness from 0.05 to 0.5.

Unsetted biped slots of tokens. Tokens shouldn't be equipped anymore.

Share this post


Link to post

 

Is it possible to adjust maximum size for part more than 6, or it is limited by the BodyMorph?

 

Also, your bodymorph token using a slot that some clothes uses(for example: some outfits from coito ergo sum, some outfits from kristinas closet), so, can you try to rearrange it? I hope there is still free slots number that unused by any clothing mods.

 

It is indeed limited by BodyMorph.

Oh, alright. It doesn't really need to be equipped. I actually just set the biped slot to stop the GECK from throwing warnings, I'll just unset it from the slot. It should not be automatically equipped anymore. Will upload shortly.

 

Asdasfa,

 

First, thank you, this is what I was looking for, diversity in the NPCs adds depth to the game.

 

I have a question, is there any documentation on what the different morph elements actually do and the range in actual size? (inches and or cm)

 

I ask so I could use the statistical data of various races to set the variables to be representative. There is more then enough Anthropometry data

available to set the ranges for a race to the 70 percent zone of the various samples.

 

Any help would be appreciated.

 

I'm afraid there is no documentation about that as it is dependent on your body replacer and how it is weighted. You will have to test it yourself with the body replacer you're using.

Also, support for lower parts (Thighs, calves, feet) are removed from the latest version of BodyMorph as it messes up IK, so just leave the values at 0, 0. I just left it there just in case it comes back.

 

 

Asdasfa,

 

Okay, if I use the mean height for male caucasian in U.S. from 2013 at 5 foot 10 inches, and the scale factor from the game uses that as 1.0 with "setscale" in the console, if I know the percentage change for a single increment for each element (bone) , I should be able to extrapolate the values

and give you a good idea of the change in inches. Then one could set the female caucasian to have a mean of 5 feet 5 inches.

 

I would think one would have to change all the elements to maintain proportion of the entire body. From what I can see in the .esp each is independent. Is this correct or did I miss something?

 

fssntuff

Share this post


Link to post

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

Sign in to follow this  

×