manim icon indicating copy to clipboard operation
manim copied to clipboard

Cannot play multiple animate of the same object at the same time (use AnimationGroup)

Open one-pyy opened this issue 2 years ago • 0 comments

Describe the bug

When using AnimationGroup to play multiple animate of the same object at the same time, It will only run the one after. Code:

from manimlib import *

class Example(Scene):
    def construct(self):
        c = Circle()
        self.play(
            AnimationGroup(
                c.animate.set_fill(GREEN, opacity=0.5),
                c.animate.move_to(LEFT),
                lag_ratio=0.5
            )
        )

Wrong display or Error traceback:

Output of the above code:

Additional context

lag_ratio=0.5limits us from solving problems by using c.animate.set_fill(GREEN, opacity=0.5).move_to(LEFT). #1618

one-pyy avatar Feb 06 '23 01:02 one-pyy