MonoBehaviourExtensions.Wait

Extension Method in MonoBehaviourExtensions

Declaration

public static Coroutine Wait(this MonoBehaviour behavior, float delay, Action action)

Description

Executes an action after a delay.

Parameters

behaviorThe behavior to execute the action on.
delayThe delay in seconds.
actionThe action to execute.

Returns

CoroutineThe coroutine.