GBOwner
Summary
Section titled “Summary”Component that assigns an entity as the active owner on a user state resource.
This node can automatically or manually designate an owner_root
(such as a CharacterBody2D, NPC, or other) as the active entity within the system, enabling participation in grid-based logic.
Signals
Section titled “Signals”signal root_changed( new_root: Node )
Emits if the root owning node ever changes
Properties
Section titled “Properties”owner_root: Node :
The root node representing the entity that owns this component.
This can be a player character, AI agent, NPC, or any other node that acts as the owning entity. This node will be assigned as the active entity in the user state.
Methods
Section titled “Methods”func _init( p_owner_root: Node ) -> void
Initialize with an optional owner root node.
p_owner_root
: Node - Root node that owns this building context (optional)func resolve_gb_dependencies( p_container: GBCompositionContainer ) -> void
Resolve dependencies from the composition container.
p_container
: GBCompositionContainer - Container with system dependencies and contextfunc get_runtime_issues( ) -> Array[String]
Validates that all required dependencies and properties are properly set. Returns validation issues if dependencies are missing, empty array if valid.
return
: Array[String] - List of validation issues (empty if valid)
Source
Section titled “Source”addons/grid_building/user/gb_owner.gd
This API reference is automatically generated from the plugin source code. For implementation examples and usage guides, see the guides section.