MonoBehaviourExtensions.RepeatUntil
Extension Method in MonoBehaviourExtensions
Declaration
public static Coroutine RepeatUntil(this MonoBehaviour behavior, Func<bool> condition, Action action, float interval)
Description
Repeats an action at a set interval until a condition is met.
Parameters
behavior | The behavior to execute the action on. |
condition | The condition to check. |
action | The action to execute. |
interval | The interval to repeat the action, in seconds. |
Returns
Coroutine | The coroutine. |