Liberi
An exergame built for kids with CP!
Main Page
Classes
Files
File List
AnimatorRandomStart.cs
1
using
UnityEngine
;
2
using
System
.Collections;
3
7
public
class
AnimatorRandomStart
: MonoBehaviour
8
{
9
void
Start ()
10
{
11
Animator animator = GetComponent<Animator>();
12
animator.Play(animator.GetCurrentAnimatorStateInfo(0).nameHash, 0, Random.Range(0f, 1f));
13
}
14
}
System
AnimatorRandomStart
Starts an Animator's initial State at a random time.
Definition:
AnimatorRandomStart.cs:7
UnityEngine
Liberi
Assets
Scripts
Components
AnimatorRandomStart.cs
Generated by
1.8.10