UxrAnimatedMaterial.AnimateFloatBlink Method
Starts animating a GameObject’s material making one if its float parameters blink.
Namespace: UltimateXR.Animation.Materials
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
public static UxrAnimatedMaterial AnimateFloatBlink(
GameObject gameObject,
string varNameFloat,
float valueMin = 0f,
float valueMax = 1f,
float blinkFrequency = 3f,
float durationSeconds = -1f,
UxrMaterialMode materialMode = UxrMaterialMode.InstanceOnly,
Action finishedCallback = null
)
Parameters
- gameObject
- Type: GameObject
GameObject whose material to animate - varNameFloat
- Type: System.String
The float var name - valueMin (Optional)
- Type: System.Single
The minimum float value in the blink - valueMax (Optional)
- Type: System.Single
The maximum float value in the blink - blinkFrequency (Optional)
- Type: System.Single
The blinking frequency - durationSeconds (Optional)
- Type: System.Single
The duration in seconds. Use a negative value to keep keep blinking until stopping manually. - materialMode (Optional)
- Type: UltimateXR.Animation.Materials.UxrMaterialMode
The material mode - finishedCallback (Optional)
- Type: System.Action
Optional callback when the animation finished
Return Value
Type: UxrAnimatedMaterial
Material animation component
See Also
Reference
UxrAnimatedMaterial Class
UltimateXR.Animation.Materials Namespace