Hi everyone! I am looking to do some optimizations and ran into a problem with executing actions on a skinned mesh. Distilling the problem down, I managed to repro here: https://playground.babylonjs.com/#YG34ZR#1
In the commented parts, my own source uses scene.beginAnimation which is a really dirt simple single bone translation to move green/blue boxes up/down. How can I modify my actions to do the same w/o using beginAnimation? Ideally, I would like to run InterpolateValueAction on position.y of the boxes while keeping currStage, as it can change at runtime. Is this still possible ?
oh, that’s because I want to reduce unnecessary keyframed animations in my .babylon file to reduce filesize. I reckon that interpolateValueAction would allow me to translate a bone target which is identical to what the keyframed anim is doing. And I can move my anims into code. But as far as the doc goes, it seems like (interpolateValueAction / PlayAnimationAction ) actions cannot be manually triggered in the conditional flow of executeCodeAction?
As in, ideally it should be
if (condition A){
execute interpolateValueAction #1
} else (condition B) {
execute interpolateValueAction #2
} etc...
In the PG, there are only 2 boxes reactions but in reality, its more of having n sphere colliders with m conditions hence the currStage param to control visual result. I guess the question is whether its possible to manually execute an action that has no trigger ?
I had the fancy idea of trying out IVAs with combineAction and found that it does not respect individual action conditions ? Repro: https://playground.babylonjs.com/#YG34ZR#2
The condition is currently only checked on the main combine action and all children will execute independently of their own conditions. Let me check how best we could sort it.