Fixed in 2021.3.30f1, 2022.3.9f1, 2023.1.10f1, 2023.2.0b7, 2023.3.0a1.
When the AnimationScriptPlayable
(asp) is output to an AnimationLayerMixerPlayable
(_layerMixer) and the singleLayerOptimization
parameter is set to false when creating the _layerMixer, modifying the alpha in the asp job (refer to the code in the "ModifyBoneTest.cs") does not take effect.
- Open the "Sample" scene.
- Select the "Player" GameObject in the Hierarchy.
- Expand the "ModifyBoneTest" component in the Inspector, make sure the value of the "Single Layer Optimization" property is false.
- Enter the Play mode.
- Drag the "Bone Alpha" slider to change the value of the "Bone Alpha" property in the Inspector.
- Observe the pose of the player's head in the Scene view.
Expected result: The pose of the player's head should change according to the value of the "Bone Alpha" property.
Actual result: The pose of the player's head does not change.
You can modify the "Single Layer Optimization", "Mode", "Bone Value" and "Bone Alpha" properties to see the effect.
PS: Only modifying the "Single Layer Optimization" in Editor mode will take effect, modifying it during Play mode will not take effect.