Unity logo
Cancel
Cart
Applications
Sell Assets

Over 11,000 five-star assets

Rated by 85,000+ customers

Supported by 100,000+ forum members

Every asset moderated by Unity

This content is hosted by a third party provider that does not allow video views without acceptance of Targeting Cookies. Please set your cookie preferences for Targeting Cookies to yes if you wish to view videos from these providers.
1/3
The Dispatcher class helps run actions on the main thread in Unity. It queues actions from background threads and executes them during the Update.
Render pipeline compatibility
The Built-in Render Pipeline is Unity’s default render pipeline. It is a general-purpose render pipeline that has limited options for customization. The Universal Render Pipeline (URP) is a Scriptable Render Pipeline that is quick and easy to customize, and lets you create optimized graphics across a wide range of platforms. The High Definition Render Pipeline (HDRP) is a Scriptable Render Pipeline that lets you create cutting-edge, high-fidelity graphics on high-end platforms.
Unity VersionBuilt-inURPHDRP
2021.3.31f1
Compatible
Compatible
Compatible
Description

The Dispatcher class helps run actions on the main thread in Unity. It queues actions from background threads and executes them during the Update. It also limits the time spent on each action to keep the frame rate smooth.


Usage:
1) Add Empty GameObject to Scene
2) Add Component -> Dispatcher
3) Write code in background thread function:

Dispatcher.Current.BeginInvoke(() =>
{
Output.text += param;
Output.text += Environment.NewLine;
});

The action will be executed on the main thread.

Complete the demo script in DispatcherTest.cs.

Dispatcher

(16)
117 users have favourite this asset
(117)
FREE
License type
File size
15.9 KB
Latest version
1.1
Latest release date
Mar 13, 2025
Original Unity version
2021.3.31
Quality assets
Over 11,000 five-star assets
Trusted
Rated by 85,000+ customers
Community support
Supported by 100,000+ forum members
Unity logo
Language
Feedback
Partners Program
Partners
USD
EUR
Copyright © 2025 Unity Technologies
All prices are exclusive of tax
USD
EUR