20 lines
328 B
C#
20 lines
328 B
C#
|
using UnityEngine;
|
|||
|
using System.Collections;
|
|||
|
|
|||
|
[RequireComponent(typeof(AudioSource))]
|
|||
|
public class Large_door_demo : MonoBehaviour {
|
|||
|
|
|||
|
public Animator animator;
|
|||
|
|
|||
|
void Start () {
|
|||
|
|
|||
|
}
|
|||
|
|
|||
|
void OnTriggerEnter(Collider other){
|
|||
|
animator.enabled = true;
|
|||
|
AudioSource audio = GetComponent<AudioSource> ();
|
|||
|
audio.Play ();
|
|||
|
}
|
|||
|
|
|||
|
}
|