Just switched from AR Foundation as it was too glitchy. I’m running the Object Placement example and I want to be able to hit play on a video in the environment. How do I do that without it just moving the object I have placed?
Description of the issue:
There is a method within Unity that can detect when your pointer is over a UI object, such as a menu or video, called
IsPointerOverGameObject. You can find an example of this implementation in the Event Systems component in the UnityUI package found in your Project View.
By including this method in an ‘if statement’ of the Object Placement example’s Placement Controller script, you could prevent your object from moving if the clicked object was UI.
Alternatively, you could try a Raycast that allows objects to be moved/spawned only if you’re clicking something that is, for example, not on the UI layer. I hope this helps get you started!