docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class Dispatcher

    Inheritance
    object
    Dispatcher
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.UnitySDK
    Assembly: Unity.Pixyz.UnitySDK.Editor.dll
    Syntax
    public static class Dispatcher

    Methods

    DelayFrames(int)

    Declaration
    public static Dispatcher.DelayFramesDispatch DelayFrames(int frames)
    Parameters
    Type Name Description
    int frames
    Returns
    Type Description
    Dispatcher.DelayFramesDispatch

    GoMainThread()

    Declaration
    public static Dispatcher.GoMainThreadDispatch GoMainThread()
    Returns
    Type Description
    Dispatcher.GoMainThreadDispatch

    GoThreadPool()

    Declaration
    public static Dispatcher.GoThreadPoolDispatch GoThreadPool()
    Returns
    Type Description
    Dispatcher.GoThreadPoolDispatch

    SleepForSeconds(float)

    Declaration
    public static Dispatcher.SleepForSecondsDispatch SleepForSeconds(float seconds)
    Parameters
    Type Name Description
    float seconds
    Returns
    Type Description
    Dispatcher.SleepForSecondsDispatch

    StartCoroutine(IEnumerator)

    Starts a coroutine. Similar to Unity's coroutine, except that it can switch threads. Yield instructions to use are all static methods in the Dispatcher class.

    Declaration
    public static void StartCoroutine(IEnumerator enumerable)
    Parameters
    Type Name Description
    IEnumerator enumerable

    Instruction to run

    Update()

    Update callback, connected to editor loop and game loop, in order to be able to dispatch instructions in the main thread in editor or play mode.

    Declaration
    public static void Update()

    WaitForSeconds(float)

    Declaration
    public static Dispatcher.WaitForSecondsDispatch WaitForSeconds(float seconds)
    Parameters
    Type Name Description
    float seconds
    Returns
    Type Description
    Dispatcher.WaitForSecondsDispatch
    In This Article
    • Methods
      • DelayFrames(int)
      • GoMainThread()
      • GoThreadPool()
      • SleepForSeconds(float)
      • StartCoroutine(IEnumerator)
      • Update()
      • WaitForSeconds(float)
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)