How can I get something like touch event?

I want the object to set player settings when touched. image
this is the code I used to do the same thing in different engine

thank you