Removing generated stuff via prefixes

This commit is contained in:
2024-09-08 20:12:05 +03:00
parent 41b46c9526
commit f103860c79
4 changed files with 32 additions and 0 deletions

View File

@@ -324,6 +324,9 @@ protected:
->show();
update_metadata_editor();
break;
case 30:
editor->remove_generated_stuff();
break;
case 51:
editor->set_point_to_cursor();
break;
@@ -988,6 +991,11 @@ String RoadLinesEditor::get_current_line_metadata() const
assert(lines.has(current_line));
return JSON::print(lines[current_line].metadata, "\t", true);
}
void RoadLinesEditor::remove_generated_stuff()
{
Array args;
editor->editor_command("remove_generated_stuff", args);
}
template <class T> T *RoadLinesEditor::get_as_node(const String &path)
{
Node *node = scene()->get_node(NodePath(path));