UI3DInputSystem
Enables UI interaction on 3D UI surfaces using screen touch mapping.
Create in the Editor
- Ensure there is a
UIControllerin the scene. - Create a GameObject and add
UIRect. - Add the
UI3DInputSystemcomponent.
How to Use
- Get the component with
myObject.findComponent(UI3DInputSystem.class). - Read and write the component properties to control behavior.
- Test input or layout in Play mode.
Java Example
SpatialObject myObject = /* your object */;
UI3DInputSystem comp = myObject.findComponent(UI3DInputSystem.class);
if (comp != null) {
// set the maxHitDistance value:
comp.maxHitDistance = 1f;
// read the maxHitDistance value:
float maxHitDistanceValue = comp.maxHitDistance;
}