We will be using the free Unity Personal License for Unity 2017.3 which, along with Unity 5.x, offers built-in support for the Rift. You are free to use any license available from the Unity site. Additionally, it is not required to have a Rift installed to build a VR application, but having the device installed on the same computer will shorten the development time greatly.
With the software installed, we can begin by creating a new Unity project. By default, Unity will store new projects in the same location as the previous project. For my work, I generally create a single directory for Unity projects and sub-directories for organization:
- Launch Unity 2017.3 and create a new project. I've named the project Midway and stored it with the other projects:
![](assets/79e92424-59d8-4ce1-ac0c-0bf2412a591c.jpg)
- Choose File | Build Settings... and set the platform to PC, Mac, Linux, and Standalone. You'll also need to click the Switch Platform button if you need to make a change.
- Choose Player Settings... from the button or the Edit | Project Settings | Player menu.
This will display the PlayerSetting window in the Inspector. - The Inspector panel will open displaying the PC, Mac, Linux, and Standalone settings. If these settings are not visible, return to the Build Settings window and confirm this choice.
- Turn on Virtual Reality Support under the XR Settings at the bottom of the Inspector window. For Unity 5.5 through 2017.1.2, this setting can be found in the section labeled Other Settings.
- Add the Oculus SDK if it is not present in the list.
- Close the Build Settings window.
Unity is now ready to create a VR experience. Before hitting the Play button, make sure the Oculus application is running in the background. This is the same application used to launch games and search the Oculus Store. Then run the scene by hitting the Play button. Our scene will load in the Game window and the Rift headset. But since we haven't added any GameObjects, the experience will be very boring.
Although the main camera works during this test, it will not be used during production. Instead we will use the OVRCameraRig, which comes with a host of assets, scripts, and functionalities.