Search Unity

SteamVR+VRTK - How to add locomotion?

Discussion in 'AR/VR (XR) Discussion' started by crazycrinkle, Sep 10, 2018.

  1. crazycrinkle

    crazycrinkle

    Joined:
    Jan 4, 2014
    Posts:
    26
    Hi I have a project with SteamVR and the VRTK assets installed. I've managed to set up the basic scene as in this video (starts at 5:40):


    The problem I'm facing now is that i've no idea how you add physics to it, so your player falls to the floor, and how you would add touchpad locomotion to it. I've searched all over the internet and there's a serious shortage of any information on how to do this. Any help is appreciated?
     
  2. StickyHoneybuns

    StickyHoneybuns

    Joined:
    Jan 16, 2018
    Posts:
    207
    I do not use VRTK and I recommend not using it at all. VRTK is nice as it allows non programmers to easily add functionality to their game. However, it will come back to bite you in the long run. Why? Because VRTK does not do everything and eventually you will need to write your own scripts to go beyond the capabilities of VRTK. Building a VR game is not much different then a regular 3D or even 2D game. So, using physics in VR is no different then in regular games.

    Have you done the Unity tutorials? If not, you need to take the time to do them. They are easy to follow and are extremely helpful and will answer most of your questions.

    Start here if you havn't done them already.
    https://unity3d.com/learn/tutorials/s/roll-ball-tutorial

    If you still want to use VRTK, VRTK has a tutorial for nearly everything in their package.
     
  3. crazycrinkle

    crazycrinkle

    Joined:
    Jan 4, 2014
    Posts:
    26
    They have "example" scenes, not tutorials, they do have some tutorial YT videos but the only relevant one is the one above where the guy literally gets the camera in the scene, able to look around. I have done a few unity tutorials, I just cannot understand the code/scripts, and no amount of tutorials is going to change that. That's why I'm stuck with VRTK, unless there's something better on the market.
     
  4. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    106
    There are other options that also do more or less the same thing, each is missing something, and while it is better than nothing, they are not really helping non programmers because they are chaotic, and the tutorials either confusing or outdated, and I feel these are more like ways to make sure you will need someone's help and give them work, than really help you do things on your own.
     
    StickyHoneybuns likes this.
  5. StickyHoneybuns

    StickyHoneybuns

    Joined:
    Jan 16, 2018
    Posts:
    207
    I personally believe you are getting ahead of yourself. From the looks of it you are new to making games and programming as well. Unfortunately coding/making games just doesn't happen overnight. You need to take a step back and start with the basics.

    I recommend starting with the Unity tutorials and work through them all. They will teach you the basics of game building and coding. They are very easy to follow. If/when you finish all the totorials and you still dont understand coding/scripting you may need to take a formal class from a local University to help. To be honest, what makes Unity so great is that it is heavily documented and has a tutorial for everything except specialized/advanced processes so you shouldn't need formal training to use Unity.

    If you can't script a basic roll-a-ball type game there is no way you will be able to make a completed VR game. We here can help you with scripting but noone is going to code your game for you for free.

    Also, programming is literally like learning a foreign language. At first nothing makes sense, the sentence structure is wierd and uncomfortable, and the words never come out right. However, if you do the tutorials eventually something will click in your head and you will just "get it" and everything will start falling into place. So, if you just stick with it, I promise you that you will eventually be able to code and script.

    Also, VRTK is the best of the tool kits for building VR games but as I said it can only take you so far.

    "no amount of tutorials is going to change that", Yes they will just don't give up.
     
    kavanavak likes this.
  6. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    106
    Hopefully soon we will only need programmers to create special tools that are not yet there in a game engine. Like it is in 3D and VFX. Imagine having to use programmers to create your 3D Animation, or VFX. That would be horrible having people with no creative background or studies dictating how you should do things just because they know something you can't wrap your head around.

    This is the kind of creative talent Unity is losing on a daily basis. Creative people, designers and artists who can make something awesome, but have no programming skills to do so.

    Eventually games will need programmers much less than they need today, but that day is not here yet. It's a matter of time. Sorry to suggest this, but, try Unreal if you have not already.
     
  7. markjanzen88

    markjanzen88

    Joined:
    May 31, 2017
    Posts:
    65
    As an 3d Artist, I recommend using just Steam VR SDK. Its very easy to make basic interactable VR projects without knowing any programmming. Start by placing the 'Player' prefab camera/player rig to your scene. To add locomotion its extremely easy: just add 'Teleporting' prefab and make a teleporting floor or teleport points.
     
    soleron and StickyHoneybuns like this.
  8. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    106
    Sounds great and I will give it again a try,
    Problem is SteamVR uses some deprecated features and locks you to Steam. :(
     
  9. markjanzen88

    markjanzen88

    Joined:
    May 31, 2017
    Posts:
    65
    Thats true I guess it comes down to what type of project you want to make. For me mostly making basic interactive VR/AR projects for architecture visualization type stuff it works great.
     
  10. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    106
    Yeah it would be great for a demo,but in my case the people who would use that demo do not have a Steam account nor Steam on their machine. So they wouldn't be able to use it. Asking investors t install steam and start an account in order to see your demo is just not going to work :D
     
  11. markjanzen88

    markjanzen88

    Joined:
    May 31, 2017
    Posts:
    65
    oh ok but those with HTC Vive equipment most likely already have Steam/Steam VR installed on their machines since thats basically the drivers for everything VR.
     
  12. Johnad194

    Johnad194

    Joined:
    Nov 1, 2017
    Posts:
    1
    A little late here, but I was in the "don't use VRTK" boat myself a couple months back. I am a pretty decent programmer, but wouldn't consider myself a professional. I managed to replicate much of the VRTK functionality in my projects with my own scripts fairly easily but I have since went back to it. I realized there is no sense in re-creating the wheel. I would spend hours making things that were already made in VRTK and mine were probably less optimized. Optimizing then takes more time. Why do this when there is a tool already out there that achieves everything you need plus some?

    I personally have come to like it very much. Oculus integration has quite a few things they need to fix or update (grab points on objects for one), that VRTK has already addressed, I can say their solution was better than mine.

    As for locomotion, pull up an example scene that has the locomotion type you desire and study the components to see what your Player prefab is missing then simply add them.

    Cheers!
     
  13. Hunter_Bobeck

    Hunter_Bobeck

    Joined:
    Dec 9, 2015
    Posts:
    4
    As an alternative, check out the free and open-source Moon Motion Toolkit:
    http://moonmotionproject.com
    It extends the SteamVR Interaction System's Teleportation functionality with a whole suite of locomotions and additional features.