Grid Placement

GBCompositionContainer

AUTO-GENERATED (GDScript) API entry

AUTO-GENERATED FILE — DO NOT EDIT MANUALLY

Source: resources/gb_composition_container.gd

Version: 5.0

class_name: GBCompositionContainer extends: GBResource

Signals

(none)

Exports

  • config: GBConfig
    • user-visible settings, templates, rules, and runtime checks used by the
    • systems.
      • Create and assign a GBLevelContext and a GBOwner in your scene, then
    • ensure they are wired into the container’s contexts (usually via the
    • injector). The GBLevelContext provides tilemap / tilelayer lookup and
    • spatial context required for placement and targeting. The GBOwner
    • identifies who is responsible for performing operations (a player or
    • simulated actor) and is required by many systems.
    • Validation workflow:
      1. Ensure the level is loaded and the GBLevelContext and a GBOwner
    • instance are created and assigned to the container’s contexts.
      1. The GBInjectorSystem automatically validates the complete setup after
    • dependency injection is complete. Any issues are logged via the container’s
    • logger system.
      1. For manual validation, call composition_container.get_runtime_issues()
    • to collect diagnostics, or composition_container.validate_runtime() to
    • get a boolean result.
    • Note: The injector (GBInjectorSystem) handles both dependency injection
    • and automatic validation. No manual validation calls are required in most
    • cases.

Methods

  • get_contexts -> GBContexts
  • get_states -> GBStates
  • get_logger -> GBLogger
  • get_mode_state -> ModeState
  • get_targeting_state -> GridTargetingState
  • get_building_state -> BuildingState
  • get_manipulation_state -> ManipulationState
  • get_settings -> GBSettings
    • Use the logger (get_logger creates a fallback) and fail-fast on missing config
  • get_placement_rules -> Array
  • _log_placement_rules_summary(rules: Array) -> void
    • Use the container’s logger if available so debug/browse tools can attach to it
  • get_visual_settings -> GBVisualSettings
  • get_systems_context -> GBSystemsContext
  • get_manipulation_settings -> ManipulationSettings
  • get_runtime_checks -> GBRuntimeChecks
  • get_templates -> GBTemplates
  • get_indicator_context -> IndicatorContext
  • get_actions -> GBActions
  • get_debug_settings -> GBDebugSettings
  • get_editor_issues -> Array
    • Delegate to the centralized validator using this instance and its logger
  • get_runtime_issues -> Array
  • log_runtime_issues -> Array
  • validate_editor -> bool
  • validate_runtime -> bool
  • _get_debug_settings_for_logger -> GBDebugSettings