Chapter 2 | Install MOTAR Unity SDK

In order to create their first project, users will need to install the MOTAR Unity SDK package.

The MOTAR Unity SDK does not need to be installed in order to connect Third Party Applications to MOTAR Services. If the MOTAR Unity SDK is not going to be used please access the following link to learn more about the required MOTAR API setup here.

Chapter 2 Tutorial Video

Create Unity Project

2.1. SELECT the PROJECTS TAB in Unity Hub. CLICK the NEW PROJECT button.

2.1.1. SELECT the CORE TAB and 3D Core template.

2.1.2. INPUT a PROJECT NAME. SELECT a FILE PATH to store the project.

2.1.3. CLICK the CREATE PROJECT button. Unity Hub will begin to load into the new project window (this may take several minutes). The new project will be accessible from the PROJECTS tab in Unity Hub.

Configure Project Build Settings

2.2. In the new project window, SELECT FILE then BUILD SETTINGS.

2.2.1. In the Build Settings window, VERIFY ANDROID is selected as the platform. Once verified, EXIT the Build Settings WINDOW.

If the platform is not yet set to ANDROID, the user will need to SELECT the ANDROID platform then CLICK the SWITCH PLATFORM button on the bottom of the modal.

Configure Project Package Manger

2.3. In the new project window, SELECT WINDOW then PACKAGE MANAGER.

2.3.1. SELECT the GEAR ICON in the top right corner (next to the search bar). SELECT ADVANCED PROJECT SETTINGS from the dropdown menu. A Project Settings window will pop up.

2.3.1.1. In the Project Settings window, add the scoped registry by inputting the following information. INPUT the NAME: Dynepic INPUT the URL: https://registry.hub.motar.io/ INPUT the SCOPE: com.dynepic

If the user copy-pasted the scoped registry information from this tutorial, ensure there are no extra spaces added as this will flag an error.

Step 2.3.1.2. is for Vive Focus 3 Users only. All other users skip to step 2.3.1.3.

2.3.1.2. Vive Focus 3 Users only: also CLICK the + ICON to ADD the HTC REGISTRY. INPUT the NAME: Vive INPUT the URL: https://npm-registry.vive.com INPUT the SCOPE: com.htc.upm

If the user copy-pasted the scoped registry information from this tutorial, ensure there are no extra spaces added as this will flag an error.

If the user experiences the Unity UI Bug wherein the text fields go blank, recommend CLICKING the PLAY button on the top of the screen and then immediately CLICKING the PLAY button again. This should resolve the issue.

2.3.1.3. CLICK the SAVE button (or APPLY, depending on the user’s operating system) once information is added.

2.3.1.4. EXIT the Project Settings WINDOW.

Install Packages

2.4. After returning to the Package Manager window, CLICK PACKAGES: UNITY REGISTRY. In the dropdown menu, SELECT MY REGISTRIES.

2.4.1. CLICK the INSTALL button to install the Dynepic MOTAR SDK.

For MOTAR Lab, the versions will be 0.5.27 for SDK and 0.0.16 for VS, which will differ from the example images provided in this tutorial.

If the user needs to update the SDK version, click the triangle icon to the right of the refresh button and select MANUAL RESOLVE. This will pull a new version of the package, after that the user can continue with the installation.

2.4.2. When prompted, SELECT the YES button.

2.4.3. When prompted, SELECT the I MADE A BACKUP, GO AHEAD! button. Once selected, Unity Hub will restart and relaunch the project.

If the user is looking for a new version and it is not visible, click the REFRESH button found on the left middle side of the screen.

2.4.4. SELECT DYNEPIC MOTAR VS. Then CLICK the INSTALL button.

2.4.5. After the install is complete, CLICK the TRIANGLE to the left of Samples. CLICK the IMPORT button for TUTORIAL - ALIEN INVASION.

2.4.5.1. For users building the project for the Vive Focus 3 the TUTORIAL - VIVE SUPPORT will also need to be installed, CLICK the IMPORT button for TUTORIAL - VIVE SUPPORT.

Until the next three packages in the next step are installed, the user may see errors pop up. This is expected and no action is required.

2.4.5.1.1. If users have imported the TUTORIAL - VIVE SUPPORT, the following PACKAGES are also required: VERIFY the following three PACKAGES are also listed for installation before proceeding: VIVE Wave OpenXR Plugin - Android VIVE Wave OpenXR ToolKit - Android VIVE Wave XR Plugin

2.4.5.1.2. Install all three required packages by individually SELECTING the PACKAGES and CLICKING the INSTALL button.

If the user is prompted regarding arm64 or gamma color space, CLICK FIX. If the user is prompted regarding an interaction profile, CLICK IGNORE.

If the user experiences the Unity UI Bug wherein the text fields go blank, recommend CLICKING the PLAY button on the top of the screen and then immediately CLICKING the PLAY button again. This should resolve the issue.

Please stop here!

The remainder of the tutorial will be completed in the MOTAR Lab workshop.

Last updated