Hi, i need help making a light switch in vr so that when my hand gets close to it and i press trigger(left or right) a point light turns on. However when i press trigger the light turns on no matter where i am in the world. I tried to fix it but now nothing happens no matter what.
You need to check how far from the switch you are.
A very common method, to start with, is to use a trigger box
It’s somewhere in the middle, but the concept holds…
Now i made it so that when my hand goes near it and i press the trigger it turns the light on, but i didnt know how to make it so when my hand isnt near it it doesnt work. How can i do that?
Sorry, for the confusion. The overlap is to know when the player is near the switch. That way, the player can’t use the switch unless they are there.
I am also trying to make a UI button and trying to turn on a couple of lights with one button but cannot do that. Is there a way to make this work?