Skip to main content

Overview

Frosty Toolsuite provides two main approaches to customizing the editing experience:
  1. Asset Editors: Full custom editors for specific asset types (inherit from FrostyAssetEditor)
  2. Type Editors: Custom property grid editors for specific field types (inherit from FrostyTypeEditor<T>)

FrostyAssetEditor

Create custom editors for entire asset types by inheriting from FrostyAssetEditor.

Base Class

Constructor

ILogger
required
The logger instance for the editor to use

Properties

RootObject

Gets the root object of the currently loaded asset.

RootObjects

Gets all root objects in the asset (some assets may have multiple roots).

Objects

Gets all objects in the asset, including nested objects.

AssetEntry

Gets the asset entry for the currently loaded asset.

Asset

Gets the loaded EBX asset.

AssetModified

Set to true to mark the asset as modified and save changes to the AssetManager.

Methods

SetAsset

Loads the specified asset into the editor. Called automatically by the editor framework.
AssetEntry
required
The asset entry to load

LoadAsset

Override to customize how the asset is loaded.
EbxAssetEntry
required
The asset entry to load
EbxAsset
The loaded asset

AddDependentObject

Adds a dependent object to the asset and loads it.
Guid
required
The GUID of the asset to add as a dependency

GetDependentObject

Retrieves a dependent object by GUID.
Guid
required
The GUID of the dependent asset
EbxAsset
The dependent asset, or null if not found

RefreshDependentObject

Reloads a dependent object from the AssetManager.
Guid
required
The GUID of the dependent asset to refresh

AddObject

Adds a new object to the asset.

RemoveObject

Removes an object from the asset.

RegisterToolbarItems

Override to add custom toolbar buttons to the editor.
List<ToolbarItem>
List of toolbar items to add to the editor

Closed

Override to perform cleanup when the editor is closed.

Events

OnAssetModified

Fired when the asset is modified.

Complete Example

FrostyTypeEditor

Create custom property grid editors for specific field types.

Base Class

Properties

string
default:"Value"
The property path to bind to on the item data
BindingMode
default:"TwoWay"
The binding mode for the value property
DependencyProperty
The dependency property to bind to on the editor control
IValueConverter
Optional value converter for the binding
object
Parameter to pass to the value converter
ValidationRule
Optional validation rule for the binding
bool
default:"false"
Whether to notify when the binding target is updated

Methods

CreateEditor

Creates the editor control. Called automatically by the property grid.

CustomizeEditor

Override to customize the editor after creation.

RefreshEditor

Override to refresh the editor when the value changes.

Registration

Register type editors globally using the RegisterGlobalTypeEditorAttribute:

Example: Vec3 Editor

ToolbarItem

Define custom toolbar buttons for asset editors.
string
required
Button text
string
required
Tooltip text
string
Path to icon image relative to plugin assembly
RelayCommand
required
Command to execute when clicked

See Also