diff options
Diffstat (limited to 'scene')
-rw-r--r-- | scene/resources/mesh_library.cpp | 5 | ||||
-rw-r--r-- | scene/resources/mesh_library.h | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/scene/resources/mesh_library.cpp b/scene/resources/mesh_library.cpp index 4e1ffd2ab3..e1131e7e3e 100644 --- a/scene/resources/mesh_library.cpp +++ b/scene/resources/mesh_library.cpp @@ -214,7 +214,7 @@ Vector<int> MeshLibrary::get_item_list() const { return ret; } -int MeshLibrary::find_item_name(const String &p_name) const { +int MeshLibrary::find_item_by_name(const String &p_name) const { for (Map<int, Item>::Element *E = item_map.front(); E; E = E->next()) { @@ -275,6 +275,9 @@ void MeshLibrary::_bind_methods() { ClassDB::bind_method(D_METHOD("get_item_shapes", "id"), &MeshLibrary::_get_item_shapes); ClassDB::bind_method(D_METHOD("get_item_preview", "id"), &MeshLibrary::get_item_preview); ClassDB::bind_method(D_METHOD("remove_item", "id"), &MeshLibrary::remove_item); + ClassDB::bind_method(D_METHOD("remove_item", "id"), &MeshLibrary::remove_item); + ClassDB::bind_method(D_METHOD("find_item_by_name", "name"), &MeshLibrary::find_item_by_name); + ClassDB::bind_method(D_METHOD("clear"), &MeshLibrary::clear); ClassDB::bind_method(D_METHOD("get_item_list"), &MeshLibrary::get_item_list); ClassDB::bind_method(D_METHOD("get_last_unused_item_id"), &MeshLibrary::get_last_unused_item_id); diff --git a/scene/resources/mesh_library.h b/scene/resources/mesh_library.h index 99b6b48d61..c5d23ce50f 100644 --- a/scene/resources/mesh_library.h +++ b/scene/resources/mesh_library.h @@ -84,7 +84,7 @@ public: void clear(); - int find_item_name(const String &p_name) const; + int find_item_by_name(const String &p_name) const; Vector<int> get_item_list() const; int get_last_unused_item_id() const; |