void Awake() { if (instance == null) { GameObject.DontDestroyOnLoad(this.gameObject); instance = this; } else { GameObject.Destroy(this.gameObject); } }
// Use this for initialization void Start() { audio = GameObject.Find("EnviroAudioManager").GetComponent <EnviroAudioManager>(); if (this.gameObject.tag == "Boss") { } else { enemyHealth = 100; max = enemyHealth; } }