update coffee.internal

This commit is contained in:
mob-sakai
2024-06-27 16:26:48 +09:00
parent 59f00f3cc1
commit e96b1dc7c0
4 changed files with 11 additions and 4 deletions

View File

@@ -20,6 +20,7 @@ namespace Coffee.UIParticleInternal
/// </summary>
public void Add(T rhs)
{
if (rhs == null) return;
Profiler.BeginSample("(COF)[FastAction] Add Action");
var node = s_NodePool.Rent();
node.Value = rhs;
@@ -32,6 +33,7 @@ namespace Coffee.UIParticleInternal
/// </summary>
public void Remove(T rhs)
{
if (rhs == null) return;
Profiler.BeginSample("(COF)[FastAction] Remove Action");
var node = _delegates.Find(rhs);
if (node != null)
@@ -63,6 +65,11 @@ namespace Coffee.UIParticleInternal
node = node.Next;
}
}
public void Clear()
{
_delegates.Clear();
}
}
/// <summary>