EditorSelection
Manages the EntityTree selection in the editor.
Manages the EntityTree selection in the editor.
This object manages the EntityTree selection in the editor.
Note: This class shouldn't be instantiated directly. Instead, access the singleton using EditorInterface.GetSelection.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
EditorSelectionConstructor
public EditorSelection();Methods6
AddEntityvoid
public void AddEntity(Entity node);Adds a node to the selection.
Note: The newly selected node will not be automatically edited in the inspector. If you want to edit a node, use EditorInterface.EditEntity.
| Name | Type | Default |
|---|---|---|
node | Entity | — |
Clearvoid
public void Clear();Clear the selection.
GetSelectedEntitiesReckfell.Collections.Array<Entity>
public Reckfell.Collections.Array<Entity> GetSelectedEntities();Returns the list of selected nodes.
Reckfell.Collections.Array<Entity>GetTopSelectedEntitiesReckfell.Collections.Array<Entity>
public Reckfell.Collections.Array<Entity> GetTopSelectedEntities();Returns the list of top selected nodes only, excluding any children. This is useful for performing transform operations (moving them, rotating, etc.). For example, if there is a node A with a child B and a sibling C, then selecting all three will cause this method to return only A and C. Changing the global transform of A will affect the global transform of B, so there is no need to change B separately.
Reckfell.Collections.Array<Entity>GetTransformableSelectedEntitiesReckfell.Collections.Array<Entity> · Deprecated
public Reckfell.Collections.Array<Entity> GetTransformableSelectedEntities();Returns the list of top selected nodes only, excluding any children. This is useful for performing transform operations (moving them, rotating, etc.). See EditorSelection.GetTopSelectedEntities.
Reckfell.Collections.Array<Entity>RemoveEntityvoid
public void RemoveEntity(Entity node);Removes a node from the selection.
| Name | Type | Default |
|---|---|---|
node | Entity | — |
Signals and events1
SelectionChangedEvent
public event Action SelectionChanged;Emitted when the selection changes.