Class GameObjectBrushEditor
The Brush Editor for a GameObject Brush.
Inherited Members
Namespace: UnityEditor .Tilemaps
Assembly: Unity.2D.Tilemap.Extras.Editor.dll
Syntax
[CustomEditor(typeof(GameObjectBrush))]
public class GameObjectBrushEditor : GridBrushEditorBase
Properties
brush
The GameObjectBrush for this Editor
Declaration
public GameObjectBrush brush { get; }
Property Value
Type | Description |
---|---|
Game |
canChangeZPosition
Whether the GridBrush can change Z Position.
Declaration
public override bool canChangeZPosition { get; set; }
Property Value
Type | Description |
---|---|
bool |
Overrides
validTargets
The targets that the GameObjectBrush can paint on
Declaration
public override GameObject[] validTargets { get; }
Property Value
Type | Description |
---|---|
Game |
Overrides
Methods
OnPaintInspectorGUI()
Callback for painting the inspector GUI for the GameObjectBrush in the tilemap palette. The GameObjectBrush Editor overrides this to show the usage of this Brush.
Declaration
public override void OnPaintInspectorGUI()
Overrides
OnPaintSceneGUI(GridLayout, GameObject, BoundsInt, Tool, bool)
Callback for painting the GUI for the GridBrush in the Scene View. The GameObjectBrush Editor overrides this to draw the preview of the brush when drawing lines.
Declaration
public override void OnPaintSceneGUI(GridLayout gridLayout, GameObject brushTarget, BoundsInt position, GridBrushBase.Tool tool, bool executing)
Parameters
Type | Name | Description |
---|---|---|
Grid |
gridLayout | Grid that the brush is being used on. |
Game |
brushTarget | Target of the GameObjectBrush::ref::Tool operation. By default the currently selected GameObject. |
Bounds |
position | Current selected location of the brush. |
Grid |
tool | Current GameObjectBrush::ref::Tool selected. |
bool | executing | Whether brush is being used. |