IndicatorSetupReport
Summary
Section titled “Summary”Represents a structured report of an IndicatorManager.setup_indicators() run. Holds the produced indicators plus diagnostic metadata that can be logged or asserted in tests.
Properties
Section titled “Properties”indicators: Array[RuleCheckIndicator] = []
The indicators created during setup
targeting_state: GridTargetingState
The targeting state being used for indicators to be created and tested against for placement and validation
template: PackedScene
The template being used for instantiating indicators
rules: Array[TileCheckRule] = []
The rules that were being evaluated in the creation of the indicators
tile_positions: Array[Vector2i] = []
All distinct tile positions that were used for the creation of indicators
position_rules_map: Dictionary[Vector2i, TileCheckRule] = {}
The mapping between tile positions and rules that were assigned for an indicator at those positions
indicator_test_setups: Dictionary[Node2D, IndicatorCollisionTestSetup] = {}
Collision test setups for each indicator
owner_shapes: Dictionary[Node2D, Array]
The owning node and the shapes that are owned by the nodes for nodes being processed for indicator generation
issues: Array[String] = []
The issues that occured during setup, if any
notes: Array[String] = []
Verbose diagnostic notes to detail what happened during indicator setup. These notes do not represent issues with the setup but may aid in debugging.
Methods
Section titled “Methods”get_indicators_issues( ) -> Array[String]
Lists issues that are preventing a proper indicators validation during runtime
finalize( ) -> void
Populate derived fields (distinct tiles, type counts) after core fields set.
add_issue( p_issue: String ) -> void
Add an extra issue to the report
has_issues( ) -> bool
Whether the report currently has issues. Useful as a guard check.
add_note( p_node: String ) -> void
Adds a diagnostics note to the report
set_test_setups( p_test_setups: Dictionary[Node2D, IndicatorCollisionTestSetup] ) -> void
Sets the collision object test setups for the report For each indicator that was tested
validate_setup_environment( p_test_object: Node ) -> bool
Perform preflight validation of indicator setup environment
Checks required dependencies and runtime state before indicator generation. If issues are found they are appended to the provided
IndicatorSetupReport
so callers can decide whether to abort and surface a clear error report instead of throwing exceptions.Parameters:
p_test_object
: Node - The preview/test object that will be used to derive collision shapes.p_tile_check_rules
: Array[TileCheckRule] - The set of tile rules that will be evaluated.p_report
: IndicatorSetupReport - Mutable report where discovered issues will be pushed.Returns: bool - True when the environment looks valid (no issues appended); false otherwise.
process_target( p_target: Node ) -> bool
Processes the target for the indicators generate and saves all shapes found
Returns whether it passed this stage for validating the indicator generation. False represents that the target cannot generate indicators due to it’s scene setup.
to_summary_string( ) -> String
Generates a textual summary of the indicator setup report.
Source
Section titled “Source”addons/grid_building/placement/manager/components/indicator_setup_report.gd
This page was auto-generated from GDScript source. Edit the source file to improve documentation.
Generated on 2025-09-07