diff options
Diffstat (limited to 'editor/import/resource_importer_obj.cpp')
-rw-r--r-- | editor/import/resource_importer_obj.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/editor/import/resource_importer_obj.cpp b/editor/import/resource_importer_obj.cpp index 3aa17ee581..01603c0a6a 100644 --- a/editor/import/resource_importer_obj.cpp +++ b/editor/import/resource_importer_obj.cpp @@ -57,7 +57,7 @@ static Error _parse_material_library(const String &p_path, Map<String, Ref<Stand //vertex current_name = l.replace("newmtl", "").strip_edges(); - current.instance(); + current.instantiate(); current->set_name(current_name); material_map[current_name] = current; } else if (l.begins_with("Ka ")) { @@ -207,7 +207,7 @@ static Error _parse_obj(const String &p_path, List<Ref<Mesh>> &r_meshes, bool p_ ERR_FAIL_COND_V_MSG(!f, ERR_CANT_OPEN, vformat("Couldn't open OBJ file '%s', it may not exist or not be readable.", p_path)); Ref<ArrayMesh> mesh; - mesh.instance(); + mesh.instantiate(); bool generate_tangents = p_generate_tangents; Vector3 scale_mesh = p_scale_mesh; @@ -378,7 +378,7 @@ static Error _parse_obj(const String &p_path, List<Ref<Mesh>> &r_meshes, bool p_ if (!p_single_mesh) { mesh->set_name(name); r_meshes.push_back(mesh); - mesh.instance(); + mesh.instantiate(); current_group = ""; current_material = ""; } @@ -440,7 +440,7 @@ Node *EditorOBJImporter::import_scene(const String &p_path, uint32_t p_flags, in for (List<Ref<Mesh>>::Element *E = meshes.front(); E; E = E->next()) { Ref<EditorSceneImporterMesh> mesh; - mesh.instance(); + mesh.instantiate(); Ref<Mesh> m = E->get(); for (int i = 0; i < m->get_surface_count(); i++) { mesh->add_surface(m->surface_get_primitive_type(i), m->surface_get_arrays(i), Array(), Dictionary(), m->surface_get_material(i)); |