Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
EditorSelection
Hérite de : Object
Gère la sélection du SceneTree depuis l'éditeur.
Description
Cet objet gère la sélection dans le SceneTree dans l'éditeur.
Note : Cette classe ne devrait pas être instanciée directement. Accédez plutôt à l'instance unique en utilisant EditorInterface.get_selection().
Méthodes
void |
|
void |
clear() |
void |
remove_node(node: Node) |
Signaux
selection_changed() 🔗
Émis lorsque la sélection change.
Descriptions des méthodes
Ajoute un nœud à la sélection.
Note : Le nouveau nœud sélectionné ne sera pas automatiquement modifié dans l'inspecteur. Si vous souhaitez modifier un nœud, utilisez EditorInterface.edit_node().
void clear() 🔗
Effacer la sélection.
Array[Node] get_selected_nodes() 🔗
Returns the list of selected nodes.
Array[Node] get_top_selected_nodes() 🔗
Returns the list of top selected nodes only, excluding any children. This is useful for performing transform operations (moving them, rotating, etc.).
For example, if there is a node A with a child B and a sibling C, then selecting all three will cause this method to return only A and C. Changing the global transform of A will affect the global transform of B, so there is no need to change B separately.
Array[Node] get_transformable_selected_nodes() 🔗
Obsolète : Use get_top_selected_nodes() instead.
Returns the list of top selected nodes only, excluding any children. This is useful for performing transform operations (moving them, rotating, etc.). See get_top_selected_nodes().
void remove_node(node: Node) 🔗
Supprime un nœud de la sélection.