Parameter Manipulation in Cubism SDK for Cocos Creator
When manipulating the values of model parameters in Cubism SDK for Cocos Creator, it is necessary to do so at the timing of
Component.lateUpdate() in Cocos Creator’s event function.
Click here for more information on the order of execution of Cocos Creator’s event functions.
The process of playing the AnimationClip is performed between
Component.lateUpdate() in Cocos Creator’s event functions.
If the parameter value is manipulated with
Component.update(), it will be overwritten by the value of the AnimationClip that is played immediately after.
Therefore, any manipulation of parameter values should be done after AnimationClip has set the values.
All components included with Cubism SDK for Cocos Creator manipulate parameter values from
Also, since the model’s vertex update process from the parameter values at each frame is performed in Cocos Creator’s post-draw event (Director.EVENT_AFTER_DRAW), any value manipulation later than this will not be calculated.