Vanilla Mannequin Fix Script
This is a re-worked vanilla script which replaces the default vanilla script that handles mannequin behavior.
How it works Now:
Bethesada relies on the OnLoad() event far too often and it is far too unreliable. The function fires only when a cell loads into memory and DOES NOT fire again until that cell is unloaded from memory. The game retains the last 2 cells you visited plus your current one in memory for faster loading as you move between them, but this function will never fire again until you have left the area and come back in some time later. When cells load, there are typically 3 things that happen; 3D objects are loaded, scripts run and AI packages process. The game seems to like to do these in random order and if your video card is beefy the 3D will load well before any scripts or AI processes, but if you have shall we say more of a potato, AI and scripts can fire before 3D is fully loaded. This can cause issues with the Mannequins because they will have their AI and placement managed before they are loaded, which can cause errors and also cause the mannequins to wander because the game tries to reset them before they are there and had a chance to move to begin with.
What I have done:
I have simply changed the OnLoad() functions to utilize OnCellAttach() instead which will fire EVERY time the object is loaded into the cell. I've also thrown in a loop delay so that the mannequin 3D is fully loaded and the AI has processed before it runs the placement reset function. This results in the script waiting until the Mannequin has been loaded, their AI has thought about wandering to the next nearest Navmesh location, THEN it will slap them back to their editor location instead of relying on the Xmarker heading they are linked to. The slot equip functions have not been touched at all and will behave in the same way they always have so there could still be issues with spontaneous unequip or item duplication that some people have reported over the years with the vanilla mannequins.
What you can do:
Add this to your game and test mannequins as much as possible. Give me any feedback you might have concerning performance, any lag or CTD issues (shouldn't be any) or any unexpected behaviors. I hope that this can be a solution to the age old holy grail issue of Skyrim.
Either install this as a loose file in your Skyrim installation (assuming you have NOT unpacked your BSA) or add as its own entry in your mod management program. This script does not have any altered properties, just reworked code, so it should work to add to a game already in progress. To uninstall simply remove the files. If you HAVE unpacked your scripts from the Skyrim BSA and installed this manually into your Skyrim install, you may have overwritten the loose script so you will need to re-extract it from your BSA. If you have no idea what I'm talking about then you don't need to worry, you probably haven't done any of this.