29 lines
411 B
C#
Raw Normal View History

2025-05-18 01:04:31 +08:00
using UnityEngine;
namespace G
{
public class Delay_extraEf : MonoBehaviour
{
private float _delay;
private void Start()
{
}
private void OnEnable()
{
this.GetComponent<Animation>().Play();
_delay = 3f;
}
private void Update()
{
_delay -= Time.deltaTime;
if (_delay <= 0f)
{
this.gameObject.SetActive(false);
this.GetComponent<Animation>().Stop();
}
}
}
}