BlinkingController
A class in Root.Township, Alta.Character.
Makes a character's eyes blink at random intervals by firing left and right eye triggers on an Animator. Client only: it does nothing on a headless server.
- Listed in Players and characters
- Inherits or implements
MonoBehaviour - Nested types
EyeBlinker
Constructors
| Member | What it is |
|---|---|
BlinkingController() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
8 private and internal fields
| Member | What it is |
|---|---|
private Animator animator | The Animator that has the eye blink triggers and speed parameters. |
private float blinkDuration | How long one blink takes, in seconds. Default 0.1. |
private float doubleBlinkPercentage | Chance (0 to 1) that a blink is followed by a second one. |
private BlinkingController.EyeBlinker leftBlinker | Wrapper that fires the left eye's blink trigger. |
private float maxTime | Longest wait between blinks, in seconds. Default 5. |
private float minTime | Shortest wait between blinks, in seconds. Default 2. |
private BlinkingController.EyeBlinker rightBlinker | Wrapper that fires the right eye's blink trigger. |
private float timeBetweenDoubleBlink | Wait between the two blinks of a double blink, in seconds. Default 0.3. |