Back to the Shapespark home page

Trigger when enter/exit radius area

I’m interested in starting an audio when the user enters an area and stopping it when he leaves the same area. I could potentially create a sphere, but I currently only have the option to trigger onClick.

Any thoughts!

2 Likes

Shapespark doesn’t have such functions. If you are willing to invest more work into it, you could do it with JavaScript by controlling the HTML audio elements directly. You would need to periodically check the position of the camera using the getCameraPosition API call and play pause audio based on the returned position.

1 Like