public sealed class ProxyShapeDocumentA body's proxy shapes, open for editing.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
⚠ Its own document rather than a tab of the model editor, and doc 34 says the opposite. A .vxproxyshapes is its own asset with its own GUID, its own importer and its own place in the reference graph; a model editor that edited it would be one document owning another asset's undo stack and dirty flag, and closing the model would have to decide what happens to unsaved shapes. The plan's point — that this is not a separate tool — is kept by the panel needing a rig to be useful at all, and by everything it draws going through the same gizmos a viewport already has.
⚠ The rig is supplied, not loaded. Posing a shape needs the skeleton it hangs off, and this document cannot reach a model asset. Without one the shapes are still editable — names, kinds, sizes, tags — and the three checks that need a pose simply say they need a rig, which is honest and is what a test gets.
Fields and properties (7)
public const string ExtensionWhat an authored shape set is written as.
public string AssetPathWhere the file is, absolute.
public ProxyShapeSetContent SetThe set.
public string? LoadErrorWhy the file would not read, or .
public Skeleton? RigThe rig the shapes hang off, or if the host has none.
public ShapeVocabulary? VocabularyThe vocabulary the set names, or if the host has none.
public IReadOnlyList<AnimationClip> MotionClips to play while looking for shapes that never move, or empty.
Events (1)
public Action<ProxyShapeDocument>? ChangedRaised after anything changes the set.
Methods (11)
public ProxyShapeDocument(EditorProject project, AssetId asset, string path)Opens a shape set.
public ProxyShapeRecord Add(ProxyShapeRecord shape)Adds a shape, undoably.
public bool Remove(ProxyShapeRecord shape)Removes a shape, undoably.
public ProxyShapeRecord Edit(ProxyShapeRecord shape, string label, Func<ProxyShapeRecord, ProxyShapeRecord> edit)Replaces a shape with an edited copy, undoably.
public IEditorCommand? EditCommand(ProxyShapeRecord shape, string label, ProxyShapeRecord replacement)The command that replaces a shape, without running it.
public ProxyShapeRecord? Mirror(ProxyShapeRecord shape)Adds the mirror image of a shape on the other side of the body.
public static string? Sided(string name)The same name with its side swapped, or if it has none.
public int GenerateCoarse()Marks the coarse set by generating one and taking its choices, undoably.
public IReadOnlyList<ShapeValidation> Audit(ProxyShapeSetContent? other = null)Everything worth telling somebody about this set before they ship it.
public void SetField(string label, Func<ProxyShapeSetContent, string> read, Action<ProxyShapeSetContent, string> write, string value)Changes one of the set's own fields, undoably.
protected override void SaveCore()Writes the document back to wherever it came from.
Used by (6)
- AnimationBinderVixen.Editor.AssetEditors
- AnimationWiringTestsVixen.Editor.App.Tests
- ProxyShapeEditorFactoryVixen.Editor.AssetEditors
- ProxyShapeEditorTestsVixen.Editor.AssetEditors.Tests
- ProxyShapeGizmoTargetVixen.Editor.AssetEditors
- ProxyShapeViewVixen.Editor.AssetEditors