From 6a35ec3075a419e2191f8e34c98d6ed7fbe68dd8 Mon Sep 17 00:00:00 2001 From: David Rose Date: Wed, 4 Sep 2002 03:25:29 +0000 Subject: [PATCH] setPlayRate requires 2 params --- direct/src/actor/Actor.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/direct/src/actor/Actor.py b/direct/src/actor/Actor.py index 93e0875273..b8b7d3d930 100644 --- a/direct/src/actor/Actor.py +++ b/direct/src/actor/Actor.py @@ -482,11 +482,16 @@ class Actor(PandaObject, NodePath): return controls[0].getPlayRate() - def setPlayRate(self, rate, animName=None, partName=None): - """getPlayRate(self, float, string=None, string=None) + def setPlayRate(self, rate, animName, partName=None): + """getPlayRate(self, float, string, string=None) Set the play rate of given anim for a given part. If no part is given, set for all parts in dictionary. - If no anim is given, find the current anim for the part. + + It used to be legal to let the animName default to the + currently-playing anim, but this was confusing and could lead + to the wrong anim's play rate getting set. Better to insist + on this parameter. + NOTE: sets play rate on all LODs""" for control in self.getAnimControls(animName, partName): control.setPlayRate(rate)