diff options
| author | Juan Linietsky | 2015-12-08 11:33:30 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2015-12-08 11:33:30 -0300 |
| commit | ecad3a285feabecf44aeb52c94a0d3552933bba1 (patch) | |
| tree | e48f5e6f0cd6e2d69ed4f944356c6abcf82ae438 /scene/main/node.cpp | |
| parent | 9637460331b768fdcb3b1d7bb81740c109b009d5 (diff) | |
| download | godot-ecad3a285feabecf44aeb52c94a0d3552933bba1.tar.gz godot-ecad3a285feabecf44aeb52c94a0d3552933bba1.tar.zst godot-ecad3a285feabecf44aeb52c94a0d3552933bba1.zip | |
better unique name resolution, as suggested i #3017
Diffstat (limited to 'scene/main/node.cpp')
| -rw-r--r-- | scene/main/node.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/scene/main/node.cpp b/scene/main/node.cpp index 74a61643f..a83216299 100644 --- a/scene/main/node.cpp +++ b/scene/main/node.cpp @@ -700,11 +700,7 @@ void Node::_validate_child_name(Node *p_child, bool p_force_human_readable) { if (!unique) { node_hrcr_count.ref(); -#ifdef DEBUG_ENABLED - String name = "@"+String(p_child->get_type_name())+itos(node_hrcr_count.get()); -#else - String name = "@"+itos(node_hrcr_count.get()); -#endif + String name = "@"+String(p_child->get_name())+"@"+itos(node_hrcr_count.get()); p_child->data.name=name; } } |
