Class UniformTransformScaleAffordanceReceiver
Affordance receiver that takes an object transform and applies a relative uniform scale multiplier on the start value.
Inheritance
UniformTransformScaleAffordanceReceiver
Inherited Members
Object.FindObjectsByType<T>(FindObjectsSortMode)
Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)
Object.FindFirstObjectByType<T>()
Object.FindAnyObjectByType<T>()
Object.FindFirstObjectByType<T>(FindObjectsInactive)
Object.FindAnyObjectByType<T>(FindObjectsInactive)
Namespace: UnityEngine.XR.Interaction.Toolkit.AffordanceSystem.Receiver.Transformation
Assembly: Unity.XR.Interaction.Toolkit.dll
Syntax
[AddComponentMenu("Affordance System/Receiver/Transformation/Uniform Transform Scale Affordance Receiver", 12)]
[HelpURL("https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@2.5/api/UnityEngine.XR.Interaction.Toolkit.AffordanceSystem.Receiver.Transformation.UniformTransformScaleAffordanceReceiver.html")]
public class UniformTransformScaleAffordanceReceiver : FloatAffordanceReceiver, IAffordanceStateReceiver<float>, IAsyncAffordanceStateReceiver, IAffordanceStateReceiver
Properties
transformToScale
Transform on which to apply scale value
Declaration
public Transform transformToScale { get; set; }
Property Value
Type | Description |
---|---|
Transform |
Methods
GetCurrentValueForCapture()
Function used to get the current value of the receiver's target property. Is overriden for material properties or other targets where the initial state exists outside the receiver.
Declaration
protected override float GetCurrentValueForCapture()
Returns
Type | Description |
---|---|
float | Initial value. |
Overrides
OnAffordanceValueUpdated(float)
Method that is called when the typed affordance value is updated. Implement this method in a derived class to apply the current affordance value, such as setting a material property or raising an event.
Declaration
protected override void OnAffordanceValueUpdated(float newValue)
Parameters
Type | Name | Description |
---|---|---|
float | newValue | New typed affordance value. |
Overrides
OnEnable()
See MonoBehaviour.
Declaration
protected override void OnEnable()