Skip to content

Commit

Permalink
Particles: Fixed a warning about BlendTree children speed
Browse files Browse the repository at this point in the history
Given that search engines returned nothing very useful
on that matter :

To avoid the error message :
"BlendTree child should not have a speed of 0"

Just set the ChildMotion timeScale to 1.

Signed-off-by: Voyage <voyage@miouyouyou.fr>
  • Loading branch information
vr-voyage committed Jun 22, 2022
1 parent 3d942c2 commit 8519b2e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ParticleSystem/SetupObjectParticles.cs
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,8 @@ private bool StateMachineSetupRotate(AnimatorStateMachine machineRotate)
name = "RotateParticle",
children = new ChildMotion[]
{
new ChildMotion() { motion = clips[(int)ClipIndex.ROTATE0], threshold = 0},
new ChildMotion() { motion = clips[(int)ClipIndex.ROTATE360], threshold = 1}
new ChildMotion() { motion = clips[(int)ClipIndex.ROTATE0], threshold = 0, timeScale = 1},
new ChildMotion() { motion = clips[(int)ClipIndex.ROTATE360], threshold = 1, timeScale = 1}
}
};
assetManager.GenerateAsset(rotationTree, "RotateParticle.asset");
Expand Down

0 comments on commit 8519b2e

Please sign in to comment.