UxrGrabManager.PlaceObject Method
Places a UxrGrabbableObject on an UxrGrabbableObjectAnchor. It can be placed either instantly or smoothly depending on placementType. If the object is currently being grabbed, all grips will be released. There is one exception to this: when the object is constrained to the world (IsConstrained) because in this case the constraints may prevent the grip from removing the object from the anchor again.
Namespace: UltimateXR.Manipulation
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
public bool PlaceObject(
UxrGrabbableObject grabbableObject,
UxrGrabbableObjectAnchor anchor,
UxrPlacementType placementType,
bool propagateEvents
)
Parameters
- grabbableObject
- Type: UltimateXR.Manipulation.UxrGrabbableObject
The object to place - anchor
- Type: UltimateXR.Manipulation.UxrGrabbableObjectAnchor
The anchor to place it on - placementType
- Type: UltimateXR.Manipulation.UxrPlacementType
The interpolation to use - propagateEvents
- Type: System.Boolean
Whether to propagate potential Removing/Removed/Placing/Placed events.
Return Value
Type: Boolean
Whether the object was placed or not. The placement can fail if there was a null argument or if the anchor has already an object on it.