using UnityEngine; public class LightningFlash : MonoBehaviour { public int animID; private void Awake() { switch (animID) { default: GetComponent<Animator>().Play("Lightning Flash"); break; case 1: GetComponent<Animator>().Play("Lightning Flash 1"); break; case 2: GetComponent<Animator>().Play("Lightning Flash 2"); break; } } }