Merge pull request #54070 from KoBeWi/meh_instance_2d

This commit is contained in:
Rémi Verschelde 2021-10-21 16:15:49 +02:00 committed by GitHub
commit fad7034e8b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View file

@ -96,6 +96,10 @@ Rect2 MeshInstance2D::_edit_get_rect() const {
return Node2D::_edit_get_rect();
}
bool MeshInstance2D::_edit_use_rect() const {
return mesh.is_valid();
}
#endif
MeshInstance2D::MeshInstance2D() {

View file

@ -48,6 +48,7 @@ protected:
public:
#ifdef TOOLS_ENABLED
virtual Rect2 _edit_get_rect() const override;
virtual bool _edit_use_rect() const override;
#endif
void set_mesh(const Ref<Mesh> &p_mesh);