Data_PartSwitch
This page documents the V-SwiFT module-data root object.
Purpose
Data_PartSwitch is the authored container that holds all V-SwiFT variant data for a part.
Source-backed type
C# type:
VSwift.Modules.Data.Data_PartSwitchbase type:
ModuleDatamodule behaviour type:
VSwift.Modules.Behaviours.Module_PartSwitchinterfaces:
IMassModifier
Key fields
VariantSets: list[VariantSet]ActiveVariants: list[string]PredefinedDynamicNodes: list[AttachNodeDefinition]MassModifier: float
Runtime role
VariantSetsdefines the authored switch structure.ActiveVariantsstores the currently selected variant IDs by set index.PredefinedDynamicNodesseeds attach-node data in OAB before variant transforms are applied.MassModifieris used as an OAB mass delta accumulator and participates throughIMassModifier.
OAB and UI behavior
GetPartInfoEntries(...) adds a V-SwiFT part-info section and surfaces variant-set / variant names in the OAB information panel, including tech requirement labels where present.
Example
+Data_PartSwitch {
+BodyStyle {
+Compact {}
+Extended {}
}
PredefinedDynamicNodes: [
{
nodeID: top_extra,
size: 1,
position: { x: 0, y: 1.25, z: 0 },
orientation: { x: 0, y: 1, z: 0 }
}
];
}Notes
The selected variant state is normalized at runtime. If an ActiveVariants entry is missing or no longer matches a valid variant, V-SwiFT falls back to the first variant in that set.