How to make a simple VR game using unity

Note: The VR game shown below is inspired by the famous title saber available on the Oculus store and made for learning purposes only.

What is VR?

VR Game Engines

To qualify for the Virtual Reality Game Engine category, a software must:

  1. Let a user create a custom VR video game experience.
  2. Support the creation and editing of immersive 3D experiences
  3. Integrate with hardware that supports VR, such as mobile phones or VR headsets

There are a lot of options when you go shopping but the most popular VR game engines are Unity, Unreal, and Godot. Although I have used Unreal for game development in the past, when it came to VR based game development, I preferred to use Unity.

Note: To be able to test your VR game in Oculus (my headset), you need to download the Oculus SDK plugin from the app store and install it in your unity project before you can start with the development.

You need a VR headset, a VR game engine, and headset’s plugin for the game engine


With a bit of experience in game development, 3D modeling, and animation I decided to try to build a very simple game in the makers week offered by my master’s degree program.

Oculus integration for unity


  1. Have a story or a concept
  2. Create your 3d characters
  3. Program their movements and functionalities
  4. Define constraints for the player to win or for the game to progress
  5. Design the ambiance
  6. Test and fix the issues
The layout of my unity workspace

In my case, I didn’t have to worry about the concept as I was trying to recreate the famous title “Saber”.

The characters for my game were:

  1. Main player: Two saber swords that you could pick with your virtual hands using Oculus’s controllers.
  2. Villains: Red and blue cubes and you had to kill or destroy in order to stay alive in the game.

To create the constraints I wrote scripts that were responsible for determining the direction and the speed of the movement, spawn spot of the cubes and the logic for the swords to be able to kill them — If the angle of impact is more than 120 degrees, then the cube will be destroyed!

The constraint was the player's error capacity i.e., his health would get reduced by 3rd of the maximum health, giving him 3 chances to miss the cubes. Also to make it interesting, the speed of the cubes increased by a factor of 0.5 after every 10 cubes!


Initial user testing of the game

I received the following feedback form testing:

I feel that the speed of the game is kind of slow. If you increase the speed, maybe in an incremental way, it would be very interesting. — Marcus

It’s fun to play but the music doesn’t suit the tempo of the game. You need a track that is a bit faster and exciting. — Lucy

It’s awesome! If you need me to be critical, I’d say the lighting could use a little more intensity. — Erin

Stages of development

I would like to thank Erin, Marcus, and Lucy for taking out time to test my game and give their valuable feedback. It really helped make it much more exciting!

Final Output

Overall it was a great learning experience and I enjoyed every bit of it. Now that I have some exposure to VR game development, I hope to make more complex and exciting games in the future!

If you want to collaborate on a project reach out on

Thanks for your time. I hope you enjoyed reading it!



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store