Stride-Skriptlebenszyklus
Wählt synchrone oder asynchrone Skripte danach, wann Arbeit läuft oder wartet. Macht Reihenfolge und Abbruch ausdrücklich, damit zerstörte Entitäten keine verspäteten Aktionen erhalten oder die Spielschleife blockieren.
stride-scripts-lifecycle
Entdecke, wie der Skill hilftWann ist der Skill hilfreich?
Nutze diesen Skill bei Restarbeit oder doppelten Handlern nach Objektentfernung.
Wobei hilft er dir?
- Wählt Skripttyp passend zu Ausführung und Warten.
- Verbindet Abonnements und wartende Arbeit mit Objektabbruch.
- Vermeidet unbestimmte Prioritätsreihenfolge und blockierte Spielschleifen.
Das könntest du fragen
Unser Quest-NPC startet ein verzögertes Gespräch und wartet auf eine Animation. Verlasse vor Warteende die Szene und kehre zurück. Brich Arbeit des alten NPC ab, entferne Abonnements und definiere nötige Reihenfolge: kein Geisterdialog und keine blockierte Hauptschleife.
Ausführliche Dokumentation
Hier findest du die ursprüngliche Anleitung, Beispiele und Prüfschritte des Skills in ihrer Originalsprache.
Weniger anzeigen
Stride — scripts lifecycle
Use when implementing Stride startup, synchronous or asynchronous scripts and entity teardown.
Version and project gate
Inspect Solution/project packages, exact Stride version, Game Studio/editor environment, asset and prefab files, Startup/Sync/AsyncScript usage, physics packages/backends, graphics profile and target platform. Do not assume every editor or physics feature exists on every host. Never turn a task into an engine upgrade without the user’s intent. Read the version-matching official reference when an API decision depends on it.
Work
Choose the script type from when work should run or await. Define Start/Update/Execute/Cancel ownership according to the installed API. Pair subscriptions and asynchronous work with cancellation when the entity leaves the scene. Do not rely on equal-priority execution order.
Deliver
A script lifecycle/ordering map and focused implementation with repeatable cleanup. Keep the change in the existing project structure; separate actual observations from the proposed acceptance scenario below.
Failure to prevent
AsyncScript is scheduled game work, not permission to block the main loop or ignore entity cancellation.
Acceptance scenario
Remove and re-add the entity, cancel during an await and unload the scene without duplicated handlers or late state writes. Follow the project’s execution and verification permissions. If execution or a target device is unavailable, provide the reproduction steps and name the remaining uncertainty; do not mark it passed.
Scope and sources
This skill belongs to Strider. Agent selection is restricted by Orqestria’s assigned-agent policy, including forced skill selection; instruction text alone is not an access control. These are original task workflows researched from official documentation, not a copied or endorsed vendor skill.
Enthaltene Dateien 1
SKILL.md
