SimSetter is a small collection of plugins that allow you to save and restore a specific shape to a sim clothing item.
After manipulating a sim clothing item to be shaped in a certain way, via physics grab, morph changes, or pose adjustments, these plugins will save the position of the clothing's vertices and can then restore them to that exact position. This is useful for situations where certain morphs or poses may interfere with a clothing item's initialized sim state, or other situations where a person atom or other object is interacting with the clothing item in a specific way that the sim initialization would interfere with.
The saved sim position data will account for changes in atom position and rotation, but cannot account for pose or atom scale changes. These plugins do not freeze the sim in place; the physics remain active after the vertex positions are set.
Note that the relevant clothing items must already be loaded into scene memory (though not necessarily active) before a preset is applied, otherwise the plugins will not load the sim data. Reapply the preset as needed once the items are loaded.
SimSetter.cs:
The newest script, which allows for multiple bundles of clothing sim data to be saved and applied. Functions like an amalgam of the other three scripts; similar bundle control to SheetSetter.cs, similar save/apply control to OutfitSetter.cs. Longer explanation coming soon, hopefully.
ItemSetter.cs:
ItemSetter.cs saves one set of vertex positions for a single clothing item. Best for one-offs where only one clothing item needs special attention.
Target Clothing:
Use this menu to select which clothing item to save the sim position of. Active clothing is rescanned on menu open, so if you're just scrolling through and not seeing a recently added clothing item, open the menu and it should populate.
Save Sim/Set Sim:
The Save Sim button will save the sim vertex positions of the selected Target Clothing item, as well as clothing item itself. The Set Sim button will apply these vertex positions to the saved clothing item. These actions are also available as triggers, with an additional trigger Queue Set Sim that acts the same as Set Sim but with a slight delay.
Info Box:
This box will display the selected Target Clothing item's display name, as well as the saved clothing item and its vertex count.
Set On Load/Delay:
Set On Load will, when selected, automatically load the stored sim data when the scene is loaded. The Physics Frame Delay is a settable delay, measured by physics frames in the FixedUpdate method, for the Queue Set Sim trigger. 50 physics frames = 1 second. This is needed for things like pose changes, where if the pose and sim set are triggered at the same time, a delay is required for the sim to be set properly.
Presets:
Save/Load Item Preset will save or load the vertex data for the saved clothing item to/from a file.
OutfitSetter.cs:
OutfitSetter.cs saves a single set of sim vertex positions for multiple clothing items at once.
Target Clothing:
Functions the same as ItemSetter.cs.
Save/Set Buttons:
When a Target Clothing item is selected, the (Select Clothing First) button becomes an Add [Clothing Item Name] button if the clothing item is not yet saved, or Update [Clothing Item Name] if the clothing item already has saved data. Selecting this button will save the sim vertex positions of the clothing item, overwriting any previously saved data for that item. Update All Saved Clothing will save the sim vertex positions for every clothing item already stored, but will not add new items. Set Selected Clothing Sim will apply the saved vertex positions of the Target Clothing item, if it is saved, and Set All Saved Clothing Sim will apply the saved vertex positions for all saved clothing items. There are also two additional triggers, Queue Set Sim and Queue Set Sim All, which queue loading of the Target Clothing's vertices or all saved clothing's vertices, respectively. Clear All Clothing And Sim will erase all stored data.
Info Box:
This box will display the selected Target Clothing item's display name, as well as the names of each of the saved clothing items.
Set On Load/Delay:
Functions the same as ItemSetter.cs.
Presets:
Save/Load Outfit Preset will save or load the vertex data for all saved clothing items to/from a file. Save Item Preset will save the vertex data for the Target Clothing, if any is available, and Load Item Preset will add or overwrite the data for the clothing item saved in the file; these files are the same as the ones used in SimSetter.cs and can be shared between the plugins.
SheetSetter.cs
(no screenshot yet)
SheetSetter.cs works on SimSheet atoms. It has similar Save, Set, and Preset options to the other plugins, except its preset files are unique to it and not shared with the other scripts. It also uses Bundles, which is my chosen term for different sets of saved sim data, so it can save and load multiple sim states. Each bundle represents a saved state, and bundles can be added or removed depending on how many are needed. Unlike the other scripts, SheetSetter does not account for atom root position/rotation when saving or loading, so the saved sim data will be at an absolute position in the scene rather than relative to the atom's position/rotation; this is a deliberate decision so the SimSheet atom can be moved around to whatever positions are needed to create and save certain shapes without having to later move it back to those specific positions when applying the bundle data.
Silly little demo video using ItemSetter:
After manipulating a sim clothing item to be shaped in a certain way, via physics grab, morph changes, or pose adjustments, these plugins will save the position of the clothing's vertices and can then restore them to that exact position. This is useful for situations where certain morphs or poses may interfere with a clothing item's initialized sim state, or other situations where a person atom or other object is interacting with the clothing item in a specific way that the sim initialization would interfere with.
The saved sim position data will account for changes in atom position and rotation, but cannot account for pose or atom scale changes. These plugins do not freeze the sim in place; the physics remain active after the vertex positions are set.
Note that the relevant clothing items must already be loaded into scene memory (though not necessarily active) before a preset is applied, otherwise the plugins will not load the sim data. Reapply the preset as needed once the items are loaded.
SimSetter.cs:
The newest script, which allows for multiple bundles of clothing sim data to be saved and applied. Functions like an amalgam of the other three scripts; similar bundle control to SheetSetter.cs, similar save/apply control to OutfitSetter.cs. Longer explanation coming soon, hopefully.
ItemSetter.cs:
ItemSetter.cs saves one set of vertex positions for a single clothing item. Best for one-offs where only one clothing item needs special attention.
Target Clothing:
Use this menu to select which clothing item to save the sim position of. Active clothing is rescanned on menu open, so if you're just scrolling through and not seeing a recently added clothing item, open the menu and it should populate.
Save Sim/Set Sim:
The Save Sim button will save the sim vertex positions of the selected Target Clothing item, as well as clothing item itself. The Set Sim button will apply these vertex positions to the saved clothing item. These actions are also available as triggers, with an additional trigger Queue Set Sim that acts the same as Set Sim but with a slight delay.
Info Box:
This box will display the selected Target Clothing item's display name, as well as the saved clothing item and its vertex count.
Set On Load/Delay:
Set On Load will, when selected, automatically load the stored sim data when the scene is loaded. The Physics Frame Delay is a settable delay, measured by physics frames in the FixedUpdate method, for the Queue Set Sim trigger. 50 physics frames = 1 second. This is needed for things like pose changes, where if the pose and sim set are triggered at the same time, a delay is required for the sim to be set properly.
Presets:
Save/Load Item Preset will save or load the vertex data for the saved clothing item to/from a file.
OutfitSetter.cs:
OutfitSetter.cs saves a single set of sim vertex positions for multiple clothing items at once.
Target Clothing:
Functions the same as ItemSetter.cs.
Save/Set Buttons:
When a Target Clothing item is selected, the (Select Clothing First) button becomes an Add [Clothing Item Name] button if the clothing item is not yet saved, or Update [Clothing Item Name] if the clothing item already has saved data. Selecting this button will save the sim vertex positions of the clothing item, overwriting any previously saved data for that item. Update All Saved Clothing will save the sim vertex positions for every clothing item already stored, but will not add new items. Set Selected Clothing Sim will apply the saved vertex positions of the Target Clothing item, if it is saved, and Set All Saved Clothing Sim will apply the saved vertex positions for all saved clothing items. There are also two additional triggers, Queue Set Sim and Queue Set Sim All, which queue loading of the Target Clothing's vertices or all saved clothing's vertices, respectively. Clear All Clothing And Sim will erase all stored data.
Info Box:
This box will display the selected Target Clothing item's display name, as well as the names of each of the saved clothing items.
Set On Load/Delay:
Functions the same as ItemSetter.cs.
Presets:
Save/Load Outfit Preset will save or load the vertex data for all saved clothing items to/from a file. Save Item Preset will save the vertex data for the Target Clothing, if any is available, and Load Item Preset will add or overwrite the data for the clothing item saved in the file; these files are the same as the ones used in SimSetter.cs and can be shared between the plugins.
SheetSetter.cs
(no screenshot yet)
SheetSetter.cs works on SimSheet atoms. It has similar Save, Set, and Preset options to the other plugins, except its preset files are unique to it and not shared with the other scripts. It also uses Bundles, which is my chosen term for different sets of saved sim data, so it can save and load multiple sim states. Each bundle represents a saved state, and bundles can be added or removed depending on how many are needed. Unlike the other scripts, SheetSetter does not account for atom root position/rotation when saving or loading, so the saved sim data will be at an absolute position in the scene rather than relative to the atom's position/rotation; this is a deliberate decision so the SimSheet atom can be moved around to whatever positions are needed to create and save certain shapes without having to later move it back to those specific positions when applying the bundle data.
Silly little demo video using ItemSetter: