Open from2001 opened 11 months ago
Currently the node has only interactionPosition and targetObject as output port.
Plyspatial provides the following other data in the input system and developer may want that data.
However if OnTap event node has many ports on it, it will look very complications. How about we add detailed information port as SpatialPointerState type? Then we also add a new node to get each data from SpatialPointerState.
The SpatialPointerDevice provides the following properties:
.interactionPosition: the position of the interaction in world space. This value will updated while the input is maintained and will always start on a collider.
.deltaInteractionPosition: the difference between the starting interaction position and the current interaction position.
.startInteractionPosition: the starting position of the interaction. This will always be on a collider and will only be set when the input occurs.
.startInteractionRayOrigin: the ray origin based on the user's eye gaze. This is only available when an app is in unbounded mode and will only be available when the input occurs.
.startInteractionRayDirection: the ray direction based on the user's eye gaze. This is only available when an app is in unbounded mode and will only be available when the input occurs.
.devicePosition: the position of the user's pinch (between the user's thumb and index finger). This value will be updated while the input is maintained.
.deviceRotation: the rotation of the user's pinch (between the user's thumb and index finger). This value will be updated while the input is maintained.
.kind: the interaction kind, Touch (poke), In Direct Pinch, Direct Pinch, Pointer, Stylus.
.targetId: the instance ID of the object being interacted with.
.phase: the spatial pointer touch phase of the current interaction.
.modifierKeys: any modifer keys that are active while the interaction is happening.
.targetObject: a direct reference to the game object the interaction targets.
https://docs.unity3d.com/Packages/com.unity.polyspatial.visionos@0.6/manual/PolySpatialInput.html
I'l implement visual scripting custom node for Polyspatial interaction event.