class EditorTool

book_4_sparkGenerated
code_blocksInput

Description

The EditorTool class in the Editor namespace provides a base for creating custom tools within the s&box editor environment. It offers a variety of methods and properties to interact with the editor's scene, selection, and other tools.

Members

Instance Methods

Member Name Summary
OnUpdate Called every frame to update the tool's logic.
OnEnabled Invoked when the tool is enabled.
OnDisabled Invoked when the tool is disabled.
OnSelectionChanged Called when the selection changes in the editor.
Dispose Releases resources used by the tool.
GetSubtools Return any tools that this tool wants to use.
AddOverlay Adds an overlay widget to the scene.

Instance Properties

Member Name Summary
Manager Gets the tool manager associated with this tool.
Selection Gets the current selection system.
Scene Gets the current scene being edited.
SceneOverlay Gets the overlay widget for the scene.
Camera Gets the scene camera.
Tools Gets the collection of subtools.
CurrentTool Gets the currently active tool.
Trace Create a scene trace against the current scene, using the current mouse cursor.
MeshTrace Create a trace that traces against the render meshes but not the physics world, using the current mouse cursor.
AllowGameObjectSelection If true, regular scene object selection will apply.