besty0728/unity-skills87 installs
unity-async
Advise on Unity async and lifecycle strategy
How do I install this agent skill?
npx skills add https://github.com/besty0728/unity-skills --skill unity-asyncIs this agent skill safe to install?
- Gen Agent Trust Hubpass
This skill provides documentation and coding guidelines for Unity asynchronous programming and lifecycle management. It contains no executable code, network requests, or external dependencies, posing no security risk.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
- Runlayerpass
1 file scanned · No issues
What does this agent skill do?
Unity Async Strategy
Documentation only: no REST skills.
Scope: this module covers async code written into the Unity runtime (Update, coroutines, UniTask, cancellation, lifecycle ownership). It does not cover the REST protocol's own async jobs; for jobId polling see batch.
When to use
- Deciding how runtime work should be scheduled or cleaned up
Decision ladder
- Ask first whether the task needs per-frame work at all.
- If not, prefer events, callbacks, or explicit method calls.
- For a short Unity-bound sequence, prefer a coroutine.
- Recommend
UniTaskonly when the project already uses it, or the user explicitly wants it and accepts the dependency. - Use
Updateonly for true continuous simulation, polling, or input loops that cannot be event-driven.
Specific guidance
- Avoid many unrelated
Updatemethods when an event-driven flow works. - Cache references used in hot paths.
- Always define lifecycle ownership: who starts the work, who cancels or stops it, when it is cleaned up.
- In
MonoBehaviour, preferOnEnable/OnDisable/OnDestroyfor subscribe/unsubscribe symmetry. - Use
IDisposablemainly for pure C# lifetimes, temporary subscriptions, or scope-based cleanup, not as a replacement for Unity lifecycle methods.
Output format
- Recommended scheduling model
- Why it fits
- Lifecycle / cancellation owner
- Hot-path risks
- Why the heavier alternative is unnecessary, if applicable
Pitfalls
- Do not recommend
UniTaskjust because it looks more advanced than a coroutine. - Prefer the simplest scheduling model that fits the use case.
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/besty0728/unity-skills/unity-async">View unity-async on skillZs</a>