Welcome to the complete guide to starting out your journey with Unreal Engine. In this article, we are going to go through everything on the list below.

Table Of Contents

Quick start

So you probably want to get a quick demo up and running to play around with, so let’s do it! First, download Unreal Engine 4 from their website. Next, once it is done downloading open it and select New P roject , you should get a page like this:

Later when we make our own project we are going to use the default options but for now, scroll down the list and select VR, make sure starter content is turned on and create the new project.

I should mention that you need to have SteamVR installed and your headset connected before you open the project or you won’t be able to preview your game in VR. (kind of a necessity if that’s what you are developing for) Anyway once your project is open you should see a scene like this:

This is a dummy scene with no more functionality then to give you some info on the different types of VR, you can navigate around your scene using wasd to move, right mouse button to look around, q and e to move up and down, and finally left mouse button to select things.

But I’m guessing you want to hop into VR, We need to switch to a new scene to do this. In your taskbar go to File>Open Scene this will bring up a file browser, click on VirtualRealityBP then Maps then select motion controller map.

After that you should get a screen like this:

Now you see that play button? That’s not the button you click to play. *Gasp* you actually click the drop down arrow right beside the play button and click VR preview, this launches a demo in steam VR where you can teleport around and play with blocks, when you are done, you can press esc to exit. And congratulations! you just got VR running in UE4! Now if you want to learn how to build your own game, scroll on!

Creating a VR Pawn

So let’s get to the real stuff, I don’t know about you but I like programming my own stuff. The demo is great but I want to make my own stuff. What we are going to do is create a pawn for our player to control. In Unreal Engine entities are referred to as actors, the ones directly controlled by you are referred to as pawns. Start by creating a new blank project with no starter content:

When you open it you should just see a singe blank floor, a few lights, and a player start actor. If you try doing a VR preview you will find that it will work but your motion controllers wont show up.

First, delete the player start actor, then drag a blank pawn into the scene from the left sidebar, place it in the center of the scene:

Then turn it into a blueprint with the blue button circled below.

When it asks you where to put it you can do whatever but I put mine in a new blueprints folder. It then asks for a name, call it VR_Pawn.

When you click create you should get something like the image below, this is the event graph where we do all our node coding, you can use c++ but the nodes are allot easier to use without error and I have not found them lacking in functionality.

Click on the viewport tab if you aren’t there already, you should see the screen below. This is where we edit our pawn/blueprint’s visual or physical aspects.





Rename your Default scene root (found right under the add component button) to something like VR_Pawn_Root. Then click the add component button and select camera, then name it something like head .

All right, we are almost finished. We just need to make sure that when we test/play our game it knows that we want to possess (control) our VR Pawn. To do this select your VR_Pawn component (the one right under the add component button), then in the right menu under pawn, change the Auto possess player to Player 0:

All right! We are ready to test it, collapse or close the blueprint window and make sure your scene looks like this:

No player start component and a VR_Pawn_Blueprint in the center of the floor, if you don’t have the blueprint in your scene just drag in from your asset manager at the bottom of the screen. FINALY , click the VR preview button and see if it works. You should be standing in the middle of the floor, with no motion controllers. If you are standing to the side of the floor, check if you set the auto possess player setting right or check the location of your blueprint. If it works, good job! You just laid the base for building any VR Game, we still need to add motion controllers though. That’s the next section, so scroll on!

Motion Controllers

This is on of the most important aspects of VR the ability to see your hands is very important for full immersion. Lets get started! Open up your VR pawn you created in the last section in the blueprint editor. You can do this by double clicking it in the assets browser. Make sure you are in the viewport tab so it looks like this:

Click the add component button and select motion controller, and name it Right:

Then in the details panel to the right find the Motion source setting under the motion controller section.

Next, make sure that Right is selected and click Add Component again and select a cube. Then in it’s details panel scale it down to .1 of its size:

Now duplicate the Right component by right-clicking on it and rename the duplicate Left. Also, go into its details and set it to left hand.

Surprise! you’re already done. Hit the VR preview button to test it, and you should now have cubes for hands. Next, we add input so we can actually do things!

Adding Input

In this segment are going to make a cube we can move around with the thumb pad. First, we need to set some bindings so we can get input from our motion controllers. Go to edit>project Settings then find the input section and set up your bindings like this:

Next, drag a cube into the scene and make it a blueprint, just like we did for the pawn. When its editor widow opens, switch to the event graph and delete all the default nodes:

Right-click to create new nodes and search for their names. Drag from values to create the colored lines things, just copy my code (nodes?) for now, I might do a full tutorial later. This code takes input from the right motion controller and moves the cube:

Also, a few settings to check, select the Cube_Blueprint(self) and in its details set Auto Receive Input to player 0. Also, select StaticMeshComponent(Inherited) and in its details under transform set its mobility to movable. Alright fire up your HMD and test it, you should be now able to use the thumb pad (windows MR, HTC Vive,) or thumbstick (oculus rift) to move the cube around.

Good Job! You were able to read all that? You must have liked it then. If you didn’t, there is a comments section of this page somewhere down there…

Thanks for reading if you liked this check out the rest of my site, I have Unity, AFrame, and Unreal Tutorials just waiting for you.