Magic Wand to throw fireballs

0651

Magic Wand to throw fireballs

Updated 6/21/2021: New Thumbnail (see more)

Originally published: 7/11/2019

A demo how to capture a throw-movement with VR controllers using JavaScript
Click Triggerbutton to conjure a fireball, make a throw movement while holding it and let go to throw the ball.
Check out the event comments on the Fireball and the handheld object to see how this is done.
This also illustrates:

  • how to use the variable store in JavaScript to store values for use outside of the update loop
  • how to reference a scene object from a handheld object

    Comments

     
    Loading…
    You can also:
    Loading…
    By markusTeam
    I'm the STEM Forged CEO

    Trending on blocktestbed