Create an instance of Scene class with a given scene id and optional attributes and session credentials.
const scene = await new Scene(topia, "sceneId", { attributes: { name: "My Scene" }, credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }}); Copy
const scene = await new Scene(topia, "sceneId", { attributes: { name: "My Scene" }, credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }});
Readonly
Optional
Retrieves scene details and assigns response data to the instance.
await scene.fetchSceneById();const { name } = scene; Copy
await scene.fetchSceneById();const { name } = scene;
Create an instance of Scene class with a given scene id and optional attributes and session credentials.
Example