21 lines
415 B
C#
21 lines
415 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using System.Runtime.InteropServices;
|
|
using UnityEngine;
|
|
|
|
public class Door : MonoBehaviour
|
|
{
|
|
[SerializeField] private Animator _animator;
|
|
|
|
private bool _opened;
|
|
|
|
public void Open()
|
|
{
|
|
if (_opened) return;
|
|
|
|
// move door
|
|
_animator.Play("DoorUp", 0, 0);
|
|
_opened = true;
|
|
}
|
|
}
|