More Effective Coroutines [PRO] View on Asset Store (opens in new tab)

Package details

Latest version
3.18.0
Last updated
First released
Unity version
2022.3.62 or later
Package size
113 KB
Files
5
Favorites
1,195
Views in the past week
57

Price tracking

Last checked
Tracked since
Lowest recorded
$6.00 on

Keywords

More Effective Coroutines [PRO]

by Digital Dust Inc (opens in new tab)

5.0 / 5 · 90 ratings

Ratings by stars
Number of ratings for each star rating
5 stars 90
4 stars 0
3 stars 0
2 stars 0
1 star 0

More Effective Coroutines (MEC) is an improved implementation of coroutines.

Price $20.00

Buy on Asset Store (opens in new tab)

Affiliate link · Purchases support this site

Price history

Last 6 months

USD
Price history for More Effective Coroutines [PRO], 6 months Current $20.00; lowest $6.00; highest $20.00 in this period. $0 $10 $20 Jun Jul Aug Sep Oct Nov Version 3.16.0 released 21 Jun 2026 v3.16.0 Version 3.17.0 released 6 Aug 2026 v3.17.0 Version 3.18.0 released 5 Oct 2026 v3.18.0

Asset preview

1 / 2

More Effective Coroutines [PRO] video 1

About this asset

MEC is a performance-focused replacement for Unity's coroutines: it runs faster and has more features.

When you use Unity's built-in default coroutines you will have to be very careful about how you use them or else they will allocate memory that the garbage collector later has to clean up. This can cause your app to randomly skip frames, which is the performance problem MEC was written to remove. MEC solves that issue for coroutines, while also making coroutines more powerful by running about twice as fast as Unity's default coroutines do and providing you with a host of new options that Unity's default coroutines don't have.

This is the Pro version. The free version of MEC contains the minimum set of features, whereas the Pro version contains the full set. Both versions run on the same super-fast core.

Switching between MEC coroutines and Unity's default coroutines is really easy. They can even be used side by side in the same project.

Advantages of MEC (both free and pro):

  • MEC doesn't require that your class inherit from MonoBehaviour in order to run a coroutine.
  • Coroutines can be "tagged" with a string when created, allowing you to kill or pause coroutines individually or as a group.
  • MEC contains no pre-compiled DLLs, which makes debugging easier.
  • MEC contains useful extra segments, like SlowUpdate.

Additional features found in Pro:

  • Additional segments: All the segments that are included in the free version, plus RealtimeUpdate, EditorUpdate, EditorSlowUpdate, EndOfFrame, and ManualTimeframe.
  • Additional functions: RunCoroutineSingleton for when you want to ensure that there is only ever one instance of a particular coroutine running at a time. SwitchCoroutine changes the timing segment or tag of a coroutine while running.
  • Extension methods: Delay adds a delay to the beginning of a coroutine. Append and Prepend automatically run one coroutine as soon as the previous one finishes. CancelWith extends the coroutine to automatically stop when a given condition goes out of scope. Superimpose runs two coroutines together. (which can be useful for wait or kill operations.) Hijack changes the return value of a coroutine. (which can be useful when you want to run the exact same code, but in slow motion).
  • A lot of additional ways to control a coroutine from just the handle, such as changing the segment, layer, tag, or even ending it.
  • Coroutines can be grouped so that when one is terminated or paused the others in the group do the same.

For more information, see the documentation here.

From the publisher's Asset Store listing.

Technical details

Why performance differs

Unity's default coroutines allocate on every yield return, and the garbage collection that follows is what surfaces as stutter and hitching in a project that otherwise runs clean. MEC removes that per-yield allocation, so a scene running hundreds of coroutines does not accumulate collection debt over time. Throughput is roughly twice Unity's implementation.

Timing segments

Update, FixedUpdate, LateUpdate, SlowUpdate, RealtimeUpdate, EditorUpdate, EditorSlowUpdate, EndOfFrame and ManualTimeframe. The segment scheduler decides when each coroutine resumes, and SlowUpdate is the performance lever most projects reach for first: logic that does not need to run every frame moves to a relaxed tick and stops competing for frame budget. EditorUpdate and EditorSlowUpdate run coroutines in edit mode. SwitchCoroutine moves a running coroutine between segments or tags without restarting it.

Handles, tags and groups

Every coroutine returns a handle you can pause, resume, kill, re-tag, move between layers, or switch segments on. Tags and layers group coroutines so a whole set pauses or terminates together, which pauses every gameplay coroutine while a menu is open at no per-object performance cost. RunCoroutineSingleton enforces singleton behaviour for a coroutine, guaranteeing only one instance runs at a time.

Extension methods

Delay defers the start by a number of seconds. Append and Prepend chain one coroutine onto the next. CancelWith ends a coroutine when a given object goes out of scope, removing the usual null-check bookkeeping. Superimpose runs two together. Hijack rewrites a coroutine's return value, so identical logic can run in slow motion without a second implementation.

Compatibility and debugging

No MonoBehaviour inheritance required; any class can run a coroutine. MEC ships as source with no pre-compiled DLLs, so the profiler and debugger step straight into it and performance work is measurement rather than guesswork. MEC coroutines and Unity's own run side by side in one project, so migrating an existing codebase can be incremental. WaitForSeconds and the standard yield instructions have MEC equivalents that wait the same number of seconds without allocating.

Where the difference shows

The performance gap is widest in projects with many short-lived coroutines, because per-yield allocation is what the collector eventually charges you for. Removing it flattens the sawtooth in the memory graph. On a scene with a thousand active coroutines the difference is visible in the profiler rather than theoretical, which is the only kind of performance claim worth making.

Free and Pro

Both editions share the same core, so the baseline performance is identical. Pro adds the RealtimeUpdate, EditorUpdate, EditorSlowUpdate, EndOfFrame and ManualTimeframe segments, the singleton and SwitchCoroutine functions, every extension method above, and the full set of handle controls.