Log in or register to post comments

Interact with 3D content without moving the Model

April 7, 2018 - 2:53pm #1

So I got ground plane detection working and I am using the DeployOnlyOnce script so that the model is moving every time a new plane is detected and the screen is click. No multiple content!

The problem is parts of my model content is supposed to be interactive so that when a user taps on them something happens. I got that working using the EventSystem and attaching a Physics Raycast component to the AR Camera but... When I click on my interactive GameObject in the scene the original plane finder raycast is still detecting a plane and is moving my model. 

So to address this I read in the forum that you can modify the DeployOnlyOnce script so that plane detection is disabled after the first model is placed by setting the Plane Finder GameObject to inactive. I did that and my interaction works fine but I don't want to lose the model moving functionality I still want the movement function to work and not be disabled.

What I need is a way for my screen taps on my interactive objects to be ignored by the plane finder's raycast if it is colliding with with one of my interactive GameObjects. As it is now it just shoots right through and detects a new plane and thinks it is just fine to move the model when I click the screen. Since I can't get access to the plane finder script that is generating the ray I can't alter it in any way to change it's behavior. 

Any suggestions about what I can do about this would be greatly appreciated.

Thank you.

Log in or register to post comments