I’m new to three.js and I’ve been messing around with the examples from the master.zip. Using the webgl_loader_fbx.html file as a template, I’ve loaded a model of a device with an exploding animation so you can see all the parts inside. Right now it’s repeating the animation indefinitely. Ultimately I want the explode animation to play when either the model or a button is clicked (not sure if one is easier than the other), and then I’d like it to reassemble when the model/button is clicked a second time.
How do I set it up so that the animation only plays when the model or button is pressed? And for the reassembly, can I make it play an animation in reverse or should I have a separate reassembly animation when I export my model? If it matters, I’m using an fbx.
Can anyone help me out? I apologize in advance; I’m not very experienced at coding/programming.