public void CheckPosition() { if (count == 0) { position = "up"; print("Valve 2 is in up position!"); } if (count == 1) { position = "right"; print("Valve 2 is in right position!"); } if (count == 2) { position = "down"; print("Valve 2 is in down position!"); } if (count == 3) { position = "left"; print("Valve 2 is in left position!"); anim.SetBool("stop", true); IEnumerator fadeSound1 = SoundFade.FadeOut(aud1, 0.5f); StartCoroutine(fadeSound1); gameObject.GetComponent <MeshCollider>().enabled = false; } }
public SoundEvent() { eventID = -1; sound = null; fade = new SoundFade(); }