From 8f9becba0e21eebcfe88f1afc9f8a596d8798fd8 Mon Sep 17 00:00:00 2001 From: Relintai Date: Sat, 14 Aug 2021 12:18:17 +0200 Subject: [PATCH] Removed get_substitute_for_room. It will not be needed. --- nodes/mesh_data_instance.cpp | 18 ------------------ nodes/mesh_data_instance.h | 2 -- 2 files changed, 20 deletions(-) diff --git a/nodes/mesh_data_instance.cpp b/nodes/mesh_data_instance.cpp index 9db6e22..2150e65 100644 --- a/nodes/mesh_data_instance.cpp +++ b/nodes/mesh_data_instance.cpp @@ -170,22 +170,6 @@ void MeshDataInstance::free_meshes() { } } -Node *MeshDataInstance::get_substitute_for_room() { - if (!_mesh.is_valid()) { - return nullptr; - } - - Ref m; - m.instance(); - - m->add_surface_from_arrays(Mesh::PRIMITIVE_TRIANGLES, _mesh->get_array()); - - MeshInstance *mi = memnew(MeshInstance); - mi->set_mesh(m); - - return mi; -} - MeshDataInstance::MeshDataInstance() { _dirty = false; _snap_to_mesh = false; @@ -244,6 +228,4 @@ void MeshDataInstance::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "material", PROPERTY_HINT_RESOURCE_TYPE, "Material"), "set_material", "get_material"); ClassDB::bind_method(D_METHOD("refresh"), &MeshDataInstance::refresh); - - ClassDB::bind_method(D_METHOD("get_substitute_for_room"), &MeshDataInstance::get_substitute_for_room); } diff --git a/nodes/mesh_data_instance.h b/nodes/mesh_data_instance.h index 3f6c510..1de4db9 100644 --- a/nodes/mesh_data_instance.h +++ b/nodes/mesh_data_instance.h @@ -65,8 +65,6 @@ public: void setup_material_texture(); void free_meshes(); - Node *get_substitute_for_room(); - MeshDataInstance(); ~MeshDataInstance();