From 0e5a98cdd833dbaeefaf3c640b0f1e3ef535e523 Mon Sep 17 00:00:00 2001 From: clayjohn Date: Fri, 18 Nov 2022 16:12:48 -0800 Subject: Fix drawing of 2D skeletons in the RD renderer. Also clean up skeleton code in preparation for adding them to GLES3 Properly update Mesh2D AABBs when skeleton is updated --- scene/2d/polygon_2d.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scene') diff --git a/scene/2d/polygon_2d.cpp b/scene/2d/polygon_2d.cpp index 5e77902977..2c825e8f7b 100644 --- a/scene/2d/polygon_2d.cpp +++ b/scene/2d/polygon_2d.cpp @@ -114,7 +114,7 @@ void Polygon2D::_notification(int p_what) { ObjectID new_skeleton_id; - if (skeleton_node) { + if (skeleton_node && !invert && bone_weights.size()) { RS::get_singleton()->canvas_item_attach_skeleton(get_canvas_item(), skeleton_node->get_skeleton()); new_skeleton_id = skeleton_node->get_instance_id(); } else { -- cgit v1.2.3