Skip to content
ct

Class

BrushCoordinator

Generated GDScript class reference for GridPlacement.BrushCoordinator.

Status
Draft
Version
v6.0
Updated
Development docs generated from GDScript source

This is unreleased documentation in active development. APIs, class names, and behavior may change before the final release.

Scene-free brush lifecycle coordinator. Gives the brush coordination concern its own single-responsibility home. Owns the [BrushState] instance and coordinates the start/complete/anchor/commit/cancel/paint sequence for terrain brushes. Mirrors the pattern of [TerrainPlacementService2D] (instance + configure) and [PlacementInputHandler] (instance + configure) so the brush behavior is swappable per-game by subclassing. Signal emission is intentionally NOT done here — the coordinator returns a [PlacementReport] for every paint attempt, and the host's thin delegator emits the appropriate success/failed signal. This keeps the coordinator pure (no side effects beyond state mutation in [BrushState]). Usage: var coord := BrushCoordinator.new() coord.configure(states, terrain_service) coord.set_brush_shape(PlacementEnums.ObjectTool.LINE) coord.start_terrain_brush_drag() var report := coord.complete_terrain_brush()

Source: addons/grid_placement/systems/building/components/brush_coordinator.gd

Syntax

class BrushCoordinator extends BrushServiceContract

Members

NameKindSummary
brush_statePropertyThe brush state this coordinator owns. Exposed for [PlacementInputHandler], which needs to read [member BrushState.is_terrain_dragging] etc. to resolve InputIntents.
configureMethod
set_statesMethod
set_brush_shapeMethod
start_terrain_brush_dragMethod
complete_terrain_brushMethod
complete_terrain_brush_dryMethod
complete_terrain_brush_immediateMethod
complete_terrain_drag_onlyMethod
anchor_pending_terrainMethod
commit_pendingMethod
cancel_pendingMethod
start_object_line_dragMethod
complete_object_line_dragMethod
is_object_line_draggingMethod
cancel_allMethod
is_terrain_draggingMethod
is_pendingMethod
get_brush_shapeMethod
get_drag_startMethod
get_pending_cellsMethod
get_object_line_drag_startMethod
get_brush_stateMethod
paint_with_current_brushMethod
set_terrain_contextMethod
supported_dimensionsMethod
get_runtime_issuesMethod
set_session_brush_stateMethod