This commit is contained in:
SzymonMis
2026-02-19 21:34:07 +01:00
parent 8de064552e
commit 06f9c7349d
25 changed files with 45269 additions and 346 deletions

View File

@@ -1,3 +1,4 @@
using DemonBoss.AI;
using Invector.vCharacterController.AI.FSMBehaviour;
using Lean.Pool;
using UnityEngine;
@@ -331,29 +332,5 @@ namespace DemonBoss.Magic
public float GetSequenceProgress() => meteorCount > 0 ? (float)_meteorsSpawned / meteorCount : 1f;
/// <summary>
/// Tiny helper MonoBehaviour to delay a callback without coroutines here.
/// </summary>
private sealed class DelayedInvoker : MonoBehaviour
{
private float _timeLeft;
private System.Action _callback;
public void Init(float delay, System.Action callback)
{
_timeLeft = delay;
_callback = callback;
}
private void Update()
{
_timeLeft -= Time.deltaTime;
if (_timeLeft <= 0f)
{
try { _callback?.Invoke(); }
finally { Destroy(this); }
}
}
}
}
}
}