GBActionLog

AUTO-GENERATED FILE – DO NOT EDIT MANUALLY

Shows recent messages from the grid building plugin actions within the context of the GBCompositionContainer scope

Source File: addons/grid_building/ui/actions/gb_action_log.gd

Extends: GBControl

Exported Properties

  • Property: message_log : RichTextLabel - Visual output area for where messages go when output from the build log

Private Properties

  • Property: _settings : [ActionLogSettings](./action-log-settings/) (private) - Build log settings injected from centralized configuration (private)
  • Property: _building_state : [BuildingState](./building-state/) : (private)
  • Property: _manipulation_state : [ManipulationState](./manipulation-state/) : (private)
  • Property: _mode_state : [ModeState](./mode-state/) : (private)
  • Property: _debug : [GBDebugSettings](./gb-debug-settings/) (private)
  • Property: _actions : [GBActions](./gb-actions/) (private)
  • Property: _logger : [GBLogger](./gb-logger/) (private)

Constants

  • Constant: REQUIRED_DEPENDENCIES: Array[String] = ["_actions", "_building_state", "_manipulation_state", "_mode_state"]

Public Methods

resolve_gb_dependencies

1
resolve_gb_dependencies(p_container : GBCompositionContainer) -> void

clear_log

1
clear_log()

get_settings

1
get_settings() -> ActionLogSettings

Lazy initialization for settings - only creates defaults if not injected Public getter for testing and external access


validate_setup

1
validate_setup() -> bool

Validates that all required dependencies are present


append_validation_results

1
append_validation_results(p_results : ValidationResults)

Adds validation results to the log as settings request.


append_placement_report_issues

1
append_placement_report_issues(p_report: PlacementReport) -> void

DRY helper: Adds placement report issues to the log


append_manipulation

1
append_manipulation(p_data : ManipulationData)

should_show

1
should_show(p_action : GBEnums.Action) -> bool

Checks whether the action data should show in the log or not.


Private Methods

_disconnect_building_state

1
_disconnect_building_state() -> void

Flags: private

DRY helper: Disconnect building state signals


_connect_building_state

1
_connect_building_state() -> void

Flags: private

DRY helper: Connect building state signals


_disconnect_manipulation_state

1
_disconnect_manipulation_state() -> void

Flags: private

DRY helper: Disconnect manipulation state signals


_connect_manipulation_state

1
_connect_manipulation_state() -> void

Flags: private

DRY helper: Connect manipulation state signals


_disconnect_mode_state

1
_disconnect_mode_state() -> void

Flags: private

DRY helper: Disconnect mode state signals


_connect_mode_state

1
_connect_mode_state() -> void

Flags: private

DRY helper: Connect mode state signals


_ready

1
_ready()

Flags: private


_append_issues_list

1
_append_issues_list(issues: Array[String]) -> void

Flags: private

DRY helper: Appends a list of issue strings to the message log


_print_reasons

1
2
3
4
_print_reasons(
    p_rule_results : Dictionary[PlacementRule, RuleResult],
    p_failed_only : bool = true
)

Flags: private

Prints the reasons for each rule result to the message log. p_failed_only: bool - Whether to print only failed results (default true)


_get_display_name_safe

1
_get_display_name_safe(obj: Node) -> String

Flags: private

DRY helper: Determines display name for objects with fallback


_handle_build_result

1
2
3
4
_handle_build_result(
    p_data: BuildActionData,
    is_success: bool
) -> void

Flags: private

DRY helper: Handles color and message formatting for build results


_on_build_success

1
_on_build_success(p_data: BuildActionData) -> void

Flags: private


_on_build_failed

1
_on_build_failed(p_data: BuildActionData) -> void

Flags: private


_handle_manipulation_result

1
2
3
4
_handle_manipulation_result(
    p_data: ManipulationData,
    is_finished: bool
) -> void

Flags: private

DRY helper: Handles manipulation result display with consistent color coding


_on_manipulation_started

1
_on_manipulation_started(p_data : ManipulationData) -> void

Flags: private


_on_manipulation_failed

1
_on_manipulation_failed(p_data : ManipulationData)

Flags: private


_on_manipulation_finished

1
_on_manipulation_finished(p_data : ManipulationData)

Flags: private


_on_mode_changed

1
_on_mode_changed(p_mode: GBEnums.Mode) -> void

Flags: private

Handles mode change events and outputs to action log if enabled