Răsfoiți Sursa

actor: only remove control effects of given animations in unloadAnims

The previous behavior was for unloadAnims() to remove the control effects from all animations, even when only one animation was passed in, which is unintuitive behavior.

Fixes #853
rdb 5 ani în urmă
părinte
comite
bd3dd63cbe
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      direct/src/actor/Actor.py

+ 1 - 1
direct/src/actor/Actor.py

@@ -2281,7 +2281,7 @@ class Actor(DirectObject, NodePath):
                             # our handle on them go. This is especially
                             # important if the anim control was blending
                             # animations.
-                            animDef.animControl.getPart().clearControlEffects()
+                            animDef.animControl.getPart().setControlEffect(animDef.animControl, 0.0)
                             animDef.animControl = None