Adding an animated object
An animated object runs an animation when triggered by the user.
To add an animated object:
- Import the FBX file of your asset. Click Assets > Import New Asset , navigate to your asset, and click Import .
- Repeat to import textures and audio.
- Drag and place the object from the project window.
- Create and assign material, or use the standard.
- Drag textures to your object.
-
With your object selected, click
Add Component
in the Inspector window. Add all of the following components:
- A collider of your choice. If you choose a mesh collider, make sure to specify the mesh it applies to. Keep in mind complex or extremely smooth meshes may have unpredictable results.
- Rigid Body .
- Vive Object Props (Script) .
Important : Make sure that the Vive Object Props (Script) component is at the top of the object’s hierarchy, above any meshes.
- In Vive Object Props (Script) , add your animation to the appropriate animation slot. Animations can be created in Unity or imported as FBX.
- You can add audio to the corresponding slot, which will play when that action occurs. See Adding interactive audio for details.
Make sure to test your objects, either through Unity or through exporting.