Merge pull request #117147 from RoeckVictor/fix-116944-cant-add-animation-library-twice
Remove previous animation libraries before adding them to dummy player
This commit is contained in:
commit
27b004f4b1
1 changed files with 6 additions and 0 deletions
|
|
@ -2464,6 +2464,12 @@ void AnimationPlayerEditorPlugin::_update_dummy_player(AnimationMixer *p_mixer)
|
|||
memdelete(default_node);
|
||||
|
||||
// Library list is dynamically added to property list, should be copied explicitly.
|
||||
List<StringName> existing_libs;
|
||||
dummy_player->get_animation_library_list(&existing_libs);
|
||||
for (const StringName &K : existing_libs) {
|
||||
dummy_player->remove_animation_library(K);
|
||||
}
|
||||
|
||||
List<StringName> libraries;
|
||||
p_mixer->get_animation_library_list(&libraries);
|
||||
for (const StringName &K : libraries) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue