forked from zxl/LaboratoryProtection
23 lines
462 B
C#
23 lines
462 B
C#
using Cysharp.Threading.Tasks;
|
|
|
|
using PMaker.Await;
|
|
|
|
using System.Threading;
|
|
|
|
using UnityEngine;
|
|
|
|
public class UITimer : AwaitBehaviour
|
|
{
|
|
[SerializeField]
|
|
private AwaitTimeline _timeline;
|
|
|
|
private void Reset()
|
|
{
|
|
this._timeline = this.GetComponent<AwaitTimeline>();
|
|
}
|
|
|
|
public override async UniTask WaitAsync(CancellationToken cancellationToken = default)
|
|
{
|
|
await this._timeline.WaitAsync(cancellationToken);
|
|
}
|
|
} |