scene-runtime

Implements async tasks, HTTP, timers, and restricted actions in Decentraland SDK7 scenes.

Updated Sep 11, 2026
One-click install
npx skills add https://github.com/ansonj-dev/neon-reverse --skill scene-runtime-ansonj-dev
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: scene-runtime
Source: https://github.com/ansonj-dev/neon-reverse/tree/main/agent/skills/scene-runtime
Command: npx skills add https://github.com/ansonj-dev/neon-reverse --skill scene-runtime-ansonj-dev

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Decentraland SDK7 scenes run in a single-threaded QuickJS runtime where bare promises are silently dropped, native timers are unsafe, and many APIs (teleports, emotes, external URLs) require prior player interaction. This Skill provides the correct patterns for these cross-cutting runtime APIs so scene code works in production, not just in preview. ## Core Features & Use Cases - Async & Networking: Wrap async work in executeTask, call public APIs with fetch, prove player identity to backends with signedFetch, and open WebSocket connections. - Runtime Metadata & Timing: Read scene/realm/explorer info, world time, deployed files, EngineInfo frame data, and use engine-bound timers instead of native setTimeout. - Restricted Actions & Systems: Control system execution priority, trigger movePlayerTo/teleportTo/emotes/changeRealm, manage portable experiences, and write scene tests with @dcl/sdk/testing. - Use Case: When building a multiplayer World that must call a backend to verify the player, then teleport them after a click, this Skill supplies the exact signedFetch and restricted-action patterns that survive deployment. ## Quick Start Ask the assistant to write Decentraland SDK7 scene code that fetches signed data from a backend and teleports the player after a button click, using the scene-runtime patterns.

Frequently Asked Questions about scene-runtime

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run async code in a Decentraland SDK7 scene?

Wrap async work in executeTask from @dcl/sdk/ecs, since the scene runtime is single-threaded and bare promises are silently dropped. Inside executeTask you can await fetch calls and other async operations normally.

How do I make authenticated HTTP requests from a Decentraland scene?

Use signedFetch from ~system/SignedFetch to prove the player's identity to your backend, which verifies the signed headers per ADR-44. The response body is a string, so call JSON.parse on it yourself.

Can I use setTimeout in a Decentraland SDK7 scene?

Use the engine-bound timers object from @dcl/sdk/ecs instead of native setTimeout or setInterval. Native globals may appear to work but are not bound to the scene engine and can cause subtle timing problems.

Why does my Decentraland system run in the wrong order?

In SDK7, higher priority numbers run earlier in the frame, opposite of Unity or Godot. The default priority is 100000, so pass a value above that to run before regular systems or below it to run after.

Why does movePlayerTo or teleportTo not work in my scene?

Restricted actions like movePlayerTo, teleportTo, triggerEmote, and openExternalUrl require prior player interaction such as a click before they can execute. Calls made without interaction are blocked by the runtime.

How do I test Decentraland SDK7 scene code?

Use @dcl/sdk/testing with generator-based tests that yield between frames, plus the four assertions assertEquals, assert, assertComponentValue, and deepCloseTo. Tests only run where the hosting runtime exposes the ~system/Testing module, such as CI runners.