Skip to content

Commit

Permalink
fix moving without children
Browse files Browse the repository at this point in the history
  • Loading branch information
tshirtman committed Nov 4, 2013
1 parent 0948ef4 commit 9cf9b72
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions magnet.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ def on_children(self, *args):
self.attract()

def attract(self, *args):
if not self.children:
return

if self.anims:
for a in self.anims:
a.stop(self.children[0])
Expand Down

0 comments on commit 9cf9b72

Please sign in to comment.