Local WebWorker scene. Base project for the CLI
Switch branches/tags
Nothing to show
Clone or download
Latest commit b8f605f Oct 16, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore Update example Apr 11, 2018
README.md added "usage" to the readme Jul 5, 2018
build.json Add build artifact Feb 21, 2018
package.json migrate to 4.1 Oct 16, 2018
scene.json migrate to 4.1 Oct 16, 2018
scene.tsx migrate to 4.1 Oct 16, 2018
tsconfig.json chore: update rebranded packages Apr 12, 2018

README.md

Interactive example running in a local scene

This simple example shows a scene that you can interact with by opening and closing a door. Clicking the door creates an event, which changes the scene's state. The scene's state then changes the rotation of the door, which rotates smoothly thanks to a transition.

Install the CLI

Download and install the Decentraland CLI by running the following commands:

npm i -g decentraland # install decentraland CLI
npm install           # install local dependencies

For a more details, follow the steps in the Installation guide.

After your CLI is installed, you're ready to preview the scene locally.

Previewing the scene

from the scene directory:

$:  dcl preview

Any dependencies are installed and then the CLI will open the scene in a new browser tab automatically.

The scene runs in a WebWorker, inside the user's computer.

The entire code is inside the file scene.tsx.

Usage

The large, white dot in the center of the viewport determines which object you're currently focused on. To open or close the door, walk over to it, target it with the white dot, and click.