Merge pull request #2036 from LinZezh1/fix_animation

Remove duplicate items
This commit is contained in:
Grant Sanderson 2024-09-06 10:57:32 -07:00 committed by GitHub
commit b6e5b0f34a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -117,10 +117,12 @@ class Animation(object):
# The surrounding scene typically handles
# updating of self.mobject. Besides, in
# most cases its updating is suspended anyway
return list(filter(
items = list(filter(
lambda m: m is not self.mobject,
self.get_all_mobjects()
))
items = list(set(items))
return items
def copy(self):
return deepcopy(self)