Hi everybody,
I'm working with a Raycast (or 3D at all) for the first time and so far everything worked out just fine. I am working first person, built a door which I can open and close per mouseclick, a closet etc.
But now I encountered a problem: I created a small key which I want the player to be able to pick up but the raycast fails to hit it about 80% of the time. Sometimes it works but most of the time I need to click on it repeatedly. Also I have set all the surrounding objects to the 'ignore raycast-layer.
I have attached a picture of my raycast-settings.
Is there a way to make the raycast more sensible or are my settings wrong?
Also: How does the direction vector work? Right now I use it in a 'boolish' kind-of way, just set Y and Z to true...
Also²: The debugging doesnt seem to work either, I cant see any line.
Thanks in Advance