Group Group Group Group Group Group Group Group Group

HTC Vive Tutorial for Unity | raywenderlich.com

#21

Hi!

Is the newest version of SteamVR running in the background while you’re trying to load the localhost page?

Cheers!

0 Likes

#22

Using Pose should be fine, it tracks a position and rotation in 3D so that’s exactly what you need. I’ll check my instructions to see if I missed anything.

Cheers!

0 Likes

#23

Updated steamvr is running in the background, everything says they are connected.

0 Likes

#24

My controllers for some reason are not displaying within the scene or game when I run. I skipped ahead a bit and set up controls to see if they display in the console, which they do. Any possible help?

0 Likes

#25

What web browser are you using? It seems there are some issues with firefox.
Try opening http://127.0.0.1:8998/dashboard/controllerbinding.html in Chrome for example.

0 Likes

#26

Can you see the controllers if you open the final project?

0 Likes

#27

I see something similar to what Sugma described. The Camera_Rig works fine and as far as I can tell, but the model of the left and right controllers are not being shown (and their transforms don’t change when I move the controllers – though the Guardian curtain shows up when I go out of bounds so the system sees them).

I opened the final project and the controllers DO show up there. Just trying to figure out what is the difference between the two projects.

The SteamVR_RenderModel components seem to have the same settings.

The only difference I can see outright is that SteamVR_Behaviour_Pose on each Controller won’t take a Pose Action unless I switch the SkeletonLeftHand or SkeletonRightHand Action to Type: Pose instead of Skeleton. (Similar to comment from bellegueule’s comment above).

0 Likes

#28

If I create a new project in either 2018.2 or 2018.3, import the Steam VR plugin and setup the Projects Settings > XR Settings manually, everything seems to be okay; controllers show up as expected. I just moved the assets from the Starter project and now all is well.

Just something odd about opening that Starter project for whatever reason…

0 Likes

#29

The problem does seem to be related to the Pose action that we delete from the default Action Sets. The instant I delete that, the Controllers disappear.

In the final project (see snapshot), I see that the Controller(left) and Controller(right) are using the \actions\default\in\SkeletonLeftHand and \actions\default\in\SkeletonRightHand.

The UI does not allow us to select those, however, similar to what Bellegueule commented above. Not sure how to set the correct settings to replicate what is in the final project. The SkeletonLeftHand and SkeletonRightHand don’t show up as options unless we change them to type Pose.

But then the Controllers don’t generate property after changing the value of the Pose Action.

Update: went through the whole page with Unity 2018.3.6f and an Oculus Rift (instead of the Vive). I had to leave the Pose Action instead of SkeletonLeftHand/SkeletonRightHand, and then use that for the Pose Action for both controllers. But everything else worked great. I did add a throw multiplier to increase the velocity when we release a grabbed object (not sure if that’s the Touch Controllers) but everything was a lot of fun to put together.

Thanks for the terrific introduction to these tools. Now going to poke around the example InteractionSystem that Valve provides.

1 Like

#30

The final project doesn’t seem to launch steamvr. I tried reimporting assets, unfortunately that didn’t work. Unsure if this is a problem caused by me or a change made to unity after an update.

0 Likes

#31

Hi, we are having an issue with our laser pointer. The laser is casting in the wrong direction. We have tried adjusting the rotation and position but are unable to get the laser to cast from the front of the controller outwards. Any help would be appreciated.

Edit: Problem has been fixed by using -transform.forward.

0 Likes

#32

I had a problem where the controllers wouldn’t show in the “Scene” view, only the “Box Collider”.

Fix on my problem
After another try on making this from scratch, I delete nothing from the SteamVR Input. I only rename the “Grab” just as in the lecture. Everything else I let be as it is and saves the changes and my controllers work and are seen as they should. Don’t know if deleting the “InteractUI” from input was the problem, but everything works as intended after that. Im using SteamVR 2.2 and unity 2018.3.6f1

0 Likes

#33

Hi, We are unable to grab objects. We have tried changing the pose action from skeleton to pose action. We have the trigger and Is Kinematic checkbox checked. We have checked the scripts and bindings. We have haptic feedback when pressing the trigger and SteamVR Input Live view shows grab as True. We are unable to run the final version. Is it possible it was created in an older version of Unity?

0 Likes

#34

It does seem like there’s something wrong with the projects while reading through the comments. This tutorial was written and tested with Unity 2018.3 and SteamVR 2.0 in mind, so my guess is that SteamVR has been updated in the last month causing breaking changes.
I’ll look into this once I got some spare time.

Thanks all!

0 Likes

#35

Hello!

I have downloaded the materials and opened the project in 2018.3.5f1 and it brings up a DirectoryNotFoundException…

“DirectoryNotFoundException: Could not find a part of the path “D:\Kyle\Documents\Unity Projects\Virtual Reality\HTC Vive Tutorial for Unity Starter\Introduction To HTC Vive - Starter\Library\PackageCache\com.unity.analytics@3.2.2\Tests\Editor\Unity.Analytics.StandardEvents\Unity.Analytics.StandardEvents.EditorTests.asmdef”
System.IO.FileStream…ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) (at :0)
System.IO.FileStream…ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.IO.FileOptions options, System.String msgPath, System.Boolean bFromProxy, System.Boolean useLongPath, System.Boolean checkHost) (at :0)
(wrapper remoting-invoke-with-check) System.IO.FileStream…ctor(string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare,int,System.IO.FileOptions,string,bool,bool,bool)
System.IO.StreamReader…ctor (System.String path, System.Text.Encoding encoding, System.Boolean detectEncodingFromByteOrderMarks, System.Int32 bufferSize, System.Boolean checkHost) (at :0)
System.IO.StreamReader…ctor (System.String path, System.Text.Encoding encoding, System.Boolean detectEncodingFromByteOrderMarks, System.Int32 bufferSize) (at :0)
System.IO.StreamReader…ctor (System.String path, System.Boolean detectEncodingFromByteOrderMarks) (at :0)
System.IO.StreamReader…ctor (System.String path) (at :0)
(wrapper remoting-invoke-with-check) System.IO.StreamReader…ctor(string)
System.IO.File.ReadAllText (System.String path) (at :0)
UnityEditor.Scripting.ScriptCompilation.EditorCompilation.LoadCustomScriptAssemblyFromJson (System.String path) (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorCompilation.cs:463)
UnityEditor.Scripting.ScriptCompilation.EditorCompilation.SetAllCustomScriptAssemblyJsons (System.String[] paths) (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorCompilation.cs:681)
UnityEditor.Scripting.ScriptCompilation.EditorCompilationInterface:SetAllCustomScriptAssemblyJsons(String[])”

Any chance there’s a way to stop this or should I revert back to the older version?

Thanks in advance :slight_smile:

0 Likes

#36

@blackdragonbe Can you please help with this when you get a chance? Thank you - much appreciated! :]

0 Likes

#37

This seems to be an issue with projects that started out in 2018.2 and have been converted to 2018.3.
You can create a new, empty 2018.3 project for now and copy over the Assets folder from the Starter project, that should fix that issue.
I’ll see if I can upload a clean starter project somewhere this weekend.

Cheers!

0 Likes

#38

I had the same problem with the controllers not showing. Here’s the tread I started on Github with a fix proposed that I didn’t had time to try. I’ll try tomorrow if I have time. Good luck all, hope it helps. https://github.com/ValveSoftware/steamvr_unity_plugin/issues/323#issuecomment-470785737

0 Likes

#39

I’ve started with a new, empty 2018.3 project and followed the instructions given, but still getting the same issue: controllers disappearing and not being tracked at all.

I’m currently running through @bennyfab github post to see if I can find a fix, but not really hopeful…

0 Likes

#40

@blackdragonbe Do you have any feedback about this? Thank you - much appreciated! :]

0 Likes