Hey guys,
I'm having a problem when clicking to trigger an interaction. The problem is that I seem to be able to trigger the event on click as long as my interaction controller is in the vicinity of the event trigger - within max click distance. Whether or not the click happens on an object set to the layer mask for interaction clicks.
Because I'm using mouse0 to move and to interact, I am triggering the event even when clicking away to move away from the event.
My issue is similar to the one posted here
http://faq.rpg-kit.com/discussion/4571/solved-mouse-interaction-controller-infinte-loop however the solution/workaround posted there did not fix things for me, I think because my game is 2d.
In any case the issue seems to be that clicking anywhere triggers the event, while you are close, the raycast doesn't seem to work as one may expect. Interesting though, if I remove the interact layer from the object, clicking anywhere doesn't trigger the event anymore, so the layer is used somehow, but I'm not sure I understand how.
I would appreciate any help/advice, thanks in advance!
Since you'd probably have found that already, I think it's either:
1) You also use the mouse button as Interact Key (Base/Control > Game Controls > Interaction Settings).
2) You have an Interaction HUD that has Interact on Click enabled and uses a GUI box across the entire screen.
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
1. I've had Enter set for the 'Accept' key, but even if I set the interact key to none, the issue persists.
2. I only have one HUD set up in Ork at the moment, the one for Main menu and it disappears once the scene is loaded.
My guess is that there is something up with that raycast maybe. Because it's 2d, I'm using a custom controller and camera, not sure if these could be the cause though. Please let me know if you need more info from me, I'll be sure to provide them. Thanks!
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
I'd just need a simple scene with your setup where this happens.
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Will be fixed in the next update.
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!