SceneState

Inherits: Reference < Object

Category: Core

Brief Description

A script interface to a scene file’s data.

Member Functions

Array get_connection_binds ( int idx ) const
int get_connection_count ( ) const
int get_connection_flags ( int idx ) const
String get_connection_method ( int idx ) const
String get_connection_signal ( int idx ) const
NodePath get_connection_source ( int idx ) const
NodePath get_connection_target ( int idx ) const
int get_node_count ( ) const
PoolStringArray get_node_groups ( int idx ) const
int get_node_index ( int idx ) const
PackedScene get_node_instance ( int idx ) const
String get_node_instance_placeholder ( int idx ) const
String get_node_name ( int idx ) const
NodePath get_node_owner_path ( int idx ) const
NodePath get_node_path ( int idx, bool for_parent=false ) const
int get_node_property_count ( int idx ) const
String get_node_property_name ( int idx, int prop_idx ) const
Variant get_node_property_value ( int idx, int prop_idx ) const
String get_node_type ( int idx ) const
bool is_node_instance_placeholder ( int idx ) const

Enums

enum GenEditState

  • GEN_EDIT_STATE_DISABLED = 0 — If passed to PackedScene.instance, blocks edits to the scene state.
  • GEN_EDIT_STATE_INSTANCE = 1 — If passed to PackedScene.instance, provides inherited scene resources to the local scene. Requires tools compiled.
  • GEN_EDIT_STATE_MAIN = 2 — If passed to PackedScene.instance, provides local scene resources to the local scene. Only the main scene should receive the main edit state. Requires tools compiled.

Description

Maintains a list of resources, nodes, exported and overridden properties, and built-in scripts associated with a scene.

Member Function Description

  • Array get_connection_binds ( int idx ) const

Returns the list of bound parameters for the signal at idx.

  • int get_connection_count ( ) const

Returns the number of signal connections in the scene.

  • int get_connection_flags ( int idx ) const

Returns the flags for the signal at idx. See Object’s CONNECT_* flags.

  • String get_connection_method ( int idx ) const

Returns the method connected to the signal at idx.

  • String get_connection_signal ( int idx ) const

Returns the name of the signal at idx.

Returns the path to the node that owns the signal at idx, relative to the root node.

Returns the path to the node that owns the method connected to the signal at idx, relative to the root node.

  • int get_node_count ( ) const

Returns the number of nodes in the scene.

Returns the list of group names associated with the node at idx.

  • int get_node_index ( int idx ) const

Returns the scene for the node at idx or null if the node is not an instance.

  • String get_node_instance_placeholder ( int idx ) const

Returns the path to the represented scene file if the node at idx is an InstancePlaceholder.

Returns the name of the node at idx.

Returns the path to the owner of the node at idx, relative to the root node.

Returns the path to the node at idx.

  • int get_node_property_count ( int idx ) const

Returns the number of exported or overridden properties for the node at idx.

  • String get_node_property_name ( int idx, int prop_idx ) const

Returns the name of the property at prop_idx for the node at idx.

  • Variant get_node_property_value ( int idx, int prop_idx ) const

Returns the value of the property at prop_idx for the node at idx.

Returns the type of the node at idx.

  • bool is_node_instance_placeholder ( int idx ) const

Returns true if the node at idx is an InstancePlaceholder.