Half-Life VR with a Razer Hydra and Oculus Rift – Setup Guide

Update: This version of the mod is obsolete at this point, check more recent posts for information on the latest version of the mod.

 

As I’m about to release a very early version of my Half-Life VR mod updated with full positional tracking via Razer Hydra integration, I wanted to outline a few things that will hopefully help anyone interested in trying it get the best experience possible.

Installing the mod

You’ll need to have the Source SDK Base 2006 and 2007 installed via steam before installing the app.  You can download them for free under Library->Tools in steam  The installation process for the mod is simple, just download the installer from here and run it and it should take care of everything else.  There is a chance that you’ll also need to install a microsoft c++ runtime before the mod will work, if you try starting the mod and it just drops out on start, you can download the runtime here: http://www.microsoft.com/en-us/download/details.aspx?id=5555.  Once installed try to start the mod again and fingers-crossed, everything should load up fine.  If not, post a comment here, this is still very early and I’m sure there will be issues when running on some setups, I’ll do my best to sort through the issues.  Assuming the mod started up ok, you’re ready to configure a few things and start playing.

Configuring your Hydra

Use your razer hydra configuration utility to map the buttons on your hydra to the usual FPS keys you like for HL2.exe.  There are a few things you’ll need to make sure though:

  1. Don’t map anything to the analog sticks, you can do WASD emulation here but I’m already using the analog inputs directly through their api (so you get real analog movement) so anything you do here with them will conflict with that.  You can map the stick push down to a key.
  2. Don’t map any gestures or use the controller motions or this will conflict with the game actually trying to use the motion to directly control your weapons on screen.
  3. Map the right hand start button to the “L” key, this will be your recalibration control (more on that later)
  4. Map a button on your hydra to “J”, this will toggle walk mode (in tight spaces or non-combat areas this really helps maintain immersion where the standard movement speeds are unwieldy)

Assuming you’ve mapped all the controls you need, there should be more than enough buttons.

Configuring Vireio Perception

The most important part of the configuration is making sure you have vireio perception configured properly.  Assuming it’s set correctly you should be able to get a result that is near the level of native implementations but finding the right settings can be challenging.  First off, check out the vireio wiki for an in-depth guide to your one-time configuration: http://www.mtbs3d.com/wiki/index.php?title=Vireio.

Once you have the convergence and eye separation set to your liking, you may want to tweak the FOV depending on how near the lenses your eyes are.  I’ve got it defaulting to 100 degrees at install, but I actually have my rift set on the nearest adjustment and found that ~105 worked well for me.  Play with these settings in game by pulling up the console and running “fov_desired 110”.  Once you find something that really works, open up your Steam/steamapps/sourcemods/halflife-vr/cfg/autoexec.cfg and update the fov_desired and viewmodel_fov variables to the value that works best for you.

The one last thing I had to do was change the distortion factor.  You can do this in vireio (I’m using beta_11 at this point) with shift+F1.  What you’re trying to eliminate is any warping out around the edges, which is easiest to see by looking at a fixed object up and in front of you and turning your head up or down while following the object.  If it appears to warp away from you as it nears the edges, hold shift+f1 while continuing to watch it until the effect is corrected.  You can use F1 to adjust the other way if you go too far.

Unfortunately the distortion factor doesn’t currently save with your profile like the rest of the settings yet so don’t forget to do this again next time you start the game, it only takes a second once you know what you’re looking for.

Note: When running vireio perception for this mod, make sure you set tracking to “Disabled”.  I’m using the tracking information in the game directly so this vireio mouse emulation isn’t necessary (and will actually cause problems with the mod).

In-game calibration

Once your hydra controls are mapped and vireio is setup, you’re ready to play.  When you first load a map, you’ll want to calibrate your trackers so they’re all on the same page.  Make sure you’re facing forward relative to your hydra base with your head level and your right hydra controller pointed in the same direction as your head and press the start button on the right controller to calibrate.  You’ll generally want to hold it in line with your shoulder at somewhere near shoulder height and not too far in front of your shoulder.  Play with different positions to find what is suitable for you, calibrating higher means the gun is naturally lower, calibrate further forward and at rest the gun is closer to the screen.  It’s all a matter of preference from there.

You may need to occasionally do this again as rift current drifts since its magnetometer isn’t being used in the current rift apis.

If your weapon ever jumps from one spot to another (typically a fairly large jump) this means your hydra tracking wasn’t properly initialized and can’t tell which hemisphere your device is in.  Hydra sensor values are the same in mirrored locations on both sides of the base station which is why when you start up your hydra software it asks you to point the left and right at the base, which it can use to determine which of the two positions the controller is in.  I’m not sure if there is anything you can do in game here at the moment, I typically save and exit and restart my motion creator but there is likely a better way to handle this.

A Few Tips for Your First Play-through

  • Don’t expect to be amazing right of the bat (and play on easy).  It’s easy to forget how much time we’ve spent perfecting our ability to aim with a mouse, aiming with an actual physical object in 3D space is challenging at first.  It’s also really rewarding as you realize how much better you are after a few hours.
  • Try not to run and gun too much, take your time, use walk whenever you don’t need to explicitly run, take in the atmosphere, use cover and pick off the enemies, etc.  Sprinting around firing wildly and spinning around are all pretty disorienting with the rift, even though I don’t ever get motion sick it’s still just not an enjoyable experience.
Advertisements

50 thoughts on “Half-Life VR with a Razer Hydra and Oculus Rift – Setup Guide

  1. Followed the instructions, and HL2 starts loading up and right before the title screen it crashes back to desktop
    saying HL2.EXE has stopped working. Verified all the correct software installed. Even uninstalled and re-installed it.

  2. Not having much luck running the mod here, I’m afraid! I get the valve splash, and the typical blurred-background loading screen for a few seconds, but then windows [8, incidentally] tells me it has stopped working. I tried uninstalling the version of the VC++ redistributable I already had (it was newer) to use the one linked above just in case, but that made no difference.

    Gonna keep investigating though!

  3. Hey Nathan. How do i make the weapon line up with the crosshair properly? My gun can be pointed at a barrel but the crosshair isn’t on the barrel making my gun shoot inaccurately. Thanks.

  4. I get a black screen when playing, flickering to slightly visible sometimes. If i pause it( via escape ), it works perfectly, no flickering and i can move the right hand as expected. Im running with AMD 6970 crossfire( disabled one of the cards ), Eyefinity( tried without eyefinity – same issue ), AMD CCC 13.3 beta 2 with 12.11 CAP 2. I dont have any issues with default HL2 or any other games( Bioshock Infinity, DMC, the latest Tomb Raider etc. ), i may try and older driver, just thought it might be useful 🙂

  5. Hey there, first i want to say, that you’ve done awesome work here and for second: i got the razer hydra new today, but i cant get it running with your vr mod. The mod runs but the weapon is stuck to my face, very near in front of my head… So i’m asking: Can you make a tutorial for the dumbest person alive(me), to get this run…. ps: got no oculus rift yet, but soon… 😉

    • Have you tried any other hydra applications? If your cable is loose between the base station and the controllers you’ll get that. Mapping the buttons is more challenging but the controller tracking should just work.

      • I’ve tried it with portal 2, works great. In your mod, my hydra takes over the mouselook, but only horizontal…

    • Yes, but for now you can’t fully control camera in game with hydra itself, that would be fixed in next release hopefully.

  6. Hello, this might seem stupid, I am trying to configure the Hydra controller with the Motion Controller, and the Razer Configuration, but I don’t seem to be able to find the button mapping to put the calibration on the right start, what aplication are you using, and how do you do it? 🙂

    • I actually had some trouble with motion creator as well so I ended up using the older razer tools and hand edited the .mce configuration. I’ll try to post my configuration later tonight, it should work for either the razer hydra drivers or sixense motion creator.

  7. Pingback: Half-Life 2 – VR with Razer Hydra and Oculus Rift Mod Released | DSOGaming | The Dark Side Of Gaming

  8. Hey Nathan great work on this mod, I got everything working but I can’t figure out how to stop my pov from looking left and right when ever I aim the gun along the horizontal axis. I noticed in your video that your pov is fixed when you move the gun. Any ideas how to lock the pov exept when I use the analog stick?

    • You’ll need to disable the mouse emulation in your sixense motion creator profile. Configuring the hydra is unfortunately less straight forward than I’d hoped, I’ll try to put something together that installs with the mod soon.

  9. Well, I gave up configuring my Hydra… I can’t find a proper config for motion creator 2, and in-game everything is strange, controllers are swapped, gun position is strange, I don’t know how to configure hydras position.

    Someone on reddit should make a tutorial about this.

    • I got it working :D, found your mcreator file on reddit, disabled others and it worked. But it was strange at first, I run TF2 and it fixed somehow.

  10. Trying you mod and eveything installs fine, and hydra works good too. But i all looks stretched or zoomed in alittle. So when i turn
    it dont feel natural like in tuscany. I must be doing something wrong.

    • You need to lower the vireio distortion quite a bit in Half-Life 2 to make it feel normal, you can do this with shift+F1 in vireio (unless you’re on a more recent version where they changed it to something like shift+f4).

  11. The Rift part of this doesn’t work for me with Perception beta12. If “Oculus Rift” is enabled in Perception, the rendering on the game freezes when my Rift is at certain angles. (e.g. looking towards the destination during the opening train ride). If I close Perception the tracking works perfectly. Thoughts? It almost seems like perception is still sending some tracking information, even though I have it set to “No Tracking”.

    • The freezing is actually an odd bug where vireio locks the output frame (the game continues playing) whenever there isn’t a crosshair somewhere on the screen or a weapon to render… I have no idea why but I’ve put in a workaround for the next release. F

      • Hey! is your this workaround included in 1.0.7? because my game freezes all the time as soon as i get a gun.. its not playable. version 1.0.5pre works but because the aiming isn’t that good in this version i’d really prefer the newest release 🙂 thx for answer

  12. Thank you for this great work. Since Half life 2 has had Oculus Rift support added natively by Valve, is there any chance you would consider seperating the Razer Hydra section of your mod to just include that as a mod for the hl2 beta version with native oculus rift vr support?

  13. For those of you having crashes in windows 8, you may want to try right clicking on the hl2.exe, clicking on the compatibility tab, and then setting the compatibility mode to windows 7.

  14. Hey man I’ve got the mode working and i’m having fun but the the right and left joysticks are working in reverse vertically so I’m not and the right joystick is extremely slow to use to look around. Do you have any Idea what is causing that?

    here is what I did to install the mode:
    -installed Half Life 2.
    -installed Source SDK base 2006 and 2007
    -installed Half Life VR 1.0.7
    -restarted Steam.
    – Installed Motion Creator.
    – I did Copy the Half-LifeVR.mce that was installed to your \Steam\SteamApps\SourceMods\halflife-vr directory into the MotionCreator 2\configs directory, then run or refresh Motion Creator and force the HLVR config on.
    – I run Motion Creator 2 and right click on Half Life 2 VR and choose force.
    – I run Half Life VR mode from steam.

    The weapons are working fine and can be reset using the reset button, but the problem is when I walk forward using razer’s left joystick I walk back instead and vice versa. Same happens when I look around using the right joystick, it is vertically inverted and the process of looking around is extremely slow.

    That’s my feedback I hope you can help me with it and thanks a lot for the brilliant mode.

    • Hm… sounds like motion creator may be doing something really odd, you can invert a joystick in the mod by opening the console (~) and typing

      joy_forwardsensitivity “-1”

      I’m working on a bunch of improvements that should eliminate the need to use motion creator with the mod which causes a lot of odd behavior as far as I can tell but for now this might get you going. Are you using a rift as well or just a hydra?

      • Sorry to be late in replying. I couldn’t find my message when I got back so I thought it hasn’t been through. Yes I’m using the hydra only but that doesn’t matter anymore because the problem was solved.

        I found out if I unchecked all the Motion Creator’s Half Life 2 mods other than the Half Life VR (keep it checked), then I the mode runs fine. It’s just like you said “motion creator may be doing something really odd”. I already finished Half Life 2 and now playing episode one. I love your mode even though I’m not using the rift. It feels great to aim with the hydra.

  15. Hello,

    I’ve got an Occullus Rift SDK, and a Razer Naga. I’ve managed to get the Naga all sorted, and the head tracking on the Rift is working fine but i cant manage to get it to go into the rounded 3d display for the rift i just get the standard 2d display. I guess i’m missing something in the Vireo setup but can’t it to work :-s Any suggestions?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s