What is the meaning of "readable_unique_name"?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By patatra

Hye eveyone,
What is the meaning of “readable_unique_name” in “void add_child ( Node node , bool readable_unique_name=false )”? Do you have an example?

Good day,

:bust_in_silhouette: Reply From: jgodfrey

When you add a node to the scene tree, it must have a unique name within its direct parent. By default, the engine creates that name using the instanced node type, an incremented number, and some @ signs. You can see such names in the Remote scene tree when your game is running.

If you set the legible_unique_name arg to true in the add_child() call, the automatically generated names are a little more human-friendly (they don’t contain the @ symbols).

If you add a few instanced nodes with that set to true and a few with it set to false, you’ll see the difference in the naming convention in the Remote scene tree.

Generally, you don’t use those names anyway, so either way is probably fine.

Thank you for you answer.

Good Day

patatra | 2022-10-12 03:53