Open diegoboston opened 2 years ago
As far as I remember, that's not possible directly, but you should be able to make the button switch focus over to a cube and then send a keyboard event. That would be a hacky workaround, but it should work.
If you are still looking for a solution, using buttons to do moves is currently being discussed for a similar simulator called AnimCubeJS: https://github.com/cubing/AnimCubeJS/issues/33
Hi all, I'm trying to build an interactive cube that I want to drive with some buttons. Is there a way to pass moves to a cube? The examples don't seem to suggest this feature. I would build a rows of buttons (L D R F U etc) and my button's onclick would trigger a function like:
var cube = getCube() cube.move("L")
Thanks for helping.