This simple scene shows how to add animations to a GLTFComponent
and handle click events.
This scene shows you:
- How to add 3D models
- How to play animations from a 3D model
- How to toggle animations on or off from a 3D model
- How to handle click events on an entity
Install the CLI
Download and install the Decentraland CLI by running the following command:
npm i -g decentraland
Previewing the scene
Download this example and navigate to its directory, then run:
$: dcl start
Any dependencies are installed and then the CLI opens the scene in a new browser tab.
Scene Usage
Click on the shark to toggle the bite
animation on and off. The swim
animation should be always on.
Learn more about how to build your own scenes in our documentation site.
If something doesn’t work, please file an issue.
This scene is protected with a standard Apache 2 licence. See the terms and conditions in the LICENSE file.