Set Up the Scenes
Last updated
Setting Up the Scenes
Navigate to Assets -> Samples -> MOTAR SDK -> 1.0.0 -> Learn to Fly UFO (URP Only) -> Scenes.
Open BarnScene.

Navigate to Assets -> Samples -> MOTAR SDK -> 1.0.0 -> Avatar -> Resources.

Drag MOTAR_Player prefab into the Hierarchy window.

Set its Position to (0, 0, 7) and Rotation to (0, 180, 0).

Locate the Left Controller inside MOTAR_Player (MOTAR_Player -> Camera Offset).

Find the component MOTAR Controller Manager. In the Inspector window
Uncheck Smooth Motion to enable teleport movement.

In Hierarchy, find UFO_1 inside UFO_Assets.

Locate the UFO Event Manager component in the Inspector window

Click + under On UFO Animation End ().

Drag MOTAR_Vignette_1 from MOTAR_Player -> Camera Offset -> Main Camera into the new event.


From the "No Function" dropdown, select MOTARVignette -> FadeOut().


Navigate to MOTAR_Vignette_1,
Alternatively, click Add Component
Type MOTARLoadScene

Press Enter on your keyboard to add the script.
Set Scene Index to 2 in MOTARLoadScene.

Under MOTAR Vignette, click + under Fade Out Ended ().

Drag MOTAR_Vignette_1 into the event and select MOTARLoadScene -> LoadScene().

Save the scene.
In BarnScene, select MOTAR_Player and copy it (Edit -> Copy).
Open Assets -> Samples -> MOTAR SDK -> 1.0.0 -> Learn to Fly UFO (URP Only) -> Scenes -> UFOScene.
Paste MOTAR_Player into the Hierarchy.
Set its Position to (0, 0, 0) and Rotation to (0, 0, 0).

In Hierarchy, find RestartButton inside UI -> Canvas_Ending.

Locate the Button component.

Click + under On Click ().

Drag MOTAR_Vignette_1 from MOTAR_Player -> Camera Offset -> Main Camera into the event.
Select MOTARVignette -> FadeOut().

Locate MOTARLoadScene in MOTAR_Vignette_1.
Change Scene Index to 1.

Save the scene.
Last updated