From 8584737525452af00d2f813c3b3f296e6567419e Mon Sep 17 00:00:00 2001 From: aaronp64 Date: Tue, 22 Apr 2025 12:17:27 -0400 Subject: [PATCH] Sort animation nodes in AnimationNodeBlendSpace2DEditor popup menu Updated AnimationNodeBlendSpace2DEditor::_blend_space_gui_input to sort animation nodes for menu when adding new points, to match ordering in AnimationNodeBlendSpace1DEditor and AnimationNodeStateMachineEditor. Old code had the sort call before adding the node names, so it wasn't reflected in the menu. --- editor/plugins/animation_blend_space_2d_editor.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/editor/plugins/animation_blend_space_2d_editor.cpp b/editor/plugins/animation_blend_space_2d_editor.cpp index 5dde9d52a0..934300d45d 100644 --- a/editor/plugins/animation_blend_space_2d_editor.cpp +++ b/editor/plugins/animation_blend_space_2d_editor.cpp @@ -119,10 +119,11 @@ void AnimationNodeBlendSpace2DEditor::_blend_space_gui_input(const Refclear(false); animations_menu->clear(); animations_to_add.clear(); + LocalVector classes; + ClassDB::get_inheriters_from_class("AnimationRootNode", classes); classes.sort_custom(); - ClassDB::get_inheriters_from_class("AnimationRootNode", classes); menu->add_submenu_node_item(TTR("Add Animation"), animations_menu); List names;