diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2022-09-23 09:42:04 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2022-09-23 09:42:04 +0200 |
commit | 43e7db0c69fa3290c43078d7e9512bb525fb7e70 (patch) | |
tree | e110036ab983d8e4afb2a8102ab8691e225c5988 | |
parent | 414dd3a25708e5cf51d28fa8b039ce0d5ad3e1f5 (diff) | |
parent | 59f933b0e17e23bff91e3eb1fcc83992979eeb5b (diff) |
Merge pull request #66250 from nongvantinh/fixed_invalid_root_name
Fixed root name invalid at scene creation.
-rw-r--r-- | editor/scene_create_dialog.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/scene_create_dialog.cpp b/editor/scene_create_dialog.cpp index 573e57ca04..4563dbb0f7 100644 --- a/editor/scene_create_dialog.cpp +++ b/editor/scene_create_dialog.cpp @@ -133,7 +133,7 @@ void SceneCreateDialog::update_dialog() { root_name = scene_name.get_file().get_basename(); } - if (!root_name.is_valid_identifier()) { + if (root_name.is_empty() || root_name.validate_node_name().size() != root_name.size()) { update_error(node_error_label, MSG_ERROR, TTR("Invalid root node name.")); is_valid = false; } |