godot
godot copied to clipboard
Moving a group of AnimationTree graph nodes creates multiple undo entries
Godot version
v4.0.alpha.custom_build [8243c7ab5]
System information
Linux 5.18.14-arch1-1
Issue description
When drag-selecting a group of nodes in an AnimationTree graph and moving them, pressing undo (ctrl+z) un-does each move individually.
Steps to reproduce
- Add a
AnimationTree - Set the root node to a
AnimationNodeBlendTree - Add several nodes of any kind
- Click and drag to select several nodes
- Drag the nodes to a new location
- Press ctrl+z
Note that ctrl+z moves only one node back to its original position.
I noticed this with the VoxelGraph node in https://github.com/Zylann/godot_voxel as well. However, I can't repro with the VisualShader graph.
Minimal reproduction project
No response
Looks like this has to be implemented on per-graph basis: https://github.com/godotengine/godot/blob/8243c7ab5df9d341209d339ab001fd8e49ee95b3/editor/plugins/animation_blend_tree_editor_plugin.cpp#L392-L401