mirror of
https://github.com/3b1b/manim.git
synced 2025-04-13 09:47:07 +00:00
Update mobject.py
This commit is contained in:
parent
c60e97ebf9
commit
4eabaecfc8
1 changed files with 1 additions and 5 deletions
|
@ -83,14 +83,10 @@ class Mobject(object):
|
|||
return self.__class__.__name__
|
||||
|
||||
def __add__(self, other : 'Mobject'):
|
||||
assert(isinstance(other, Mobject))
|
||||
return Group(self, other)
|
||||
|
||||
def __mul__(self, other : 'int'):
|
||||
from manimlib.mobject.types.vectorized_mobject import VMobject, VGroup
|
||||
if isinstance(self, VMobject):
|
||||
return VGroup(*[self.copy() for i in range(other)])
|
||||
return Group(*[mob.copy() for mob in range(other)])
|
||||
return self.replicate(other)
|
||||
|
||||
def init_data(self):
|
||||
self.data = {
|
||||
|
|
Loading…
Add table
Reference in a new issue