Announcement

Collapse
No announcement yet.

VR Expansion Plugin

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    I'm having trouble, can't seem to make a new VR Character Actor, it doesn't show up, just the VR Basic Character. When I load the character my playspace is up off the ground and there are no motion controllers.

    Comment


      Originally posted by kusokuso1 View Post
      I'm getting seemingly intermittent crashes after having upgraded a 4.17 project (based on the VRExpTemplate) with 4.18 cl:002602841e01.

      When I updated it I just made a copy of the 4.17 project under 4.18. Deleted the Intermediate folder, replaced the old VRExpansionPlugin folder with that of the one from the aforementioned cl. Built it and got no errors.

      Tried to launch the proj and got a "couldn't find the VRexpansionPlugin extension" error or something. Deleted the Intermediate folder again, and did a Rebuild instead. This time it worked but now I often (2 out of 3 times playing in PIE) get this error:
      LogOutputDevice: Error: FMatrix::InverseFast(), trying to invert a NIL matrix, this results in NaNs! Use Inverse() instead.
      Here's the error w/ the callstack:
      http://pasteall.org/654637
      I doubt you were on the latest character anyway, it isn't Master it is still a beta branch.

      Looks like it is coming from the NonAuthorityMinimumAreaRectangle class which is a direct copy of Epics node but without authority locks. There is no NAN check and your HMD must be passing in an invalid bounding box for the tracked area.

      You didn't lose your calibration did you?


      Consider supporting me on patreon

      My Open source tools and plugins
      Advanced Sessions Plugin
      VR Expansion Plugin

      Comment


        Originally posted by AtmaStudios View Post



        For some reason your original demo 4.18 the capsule wasn't triggering overlaps. I set the head cube mesh to overlap and it worked.

        What is the best way to have the hands trigger overlaps? That seems like an important feature. I set the hands to generate overlaps as well, but then I couldn't close the drawers after opening them. I was also climbing the table.
        Don't have them overlap with VRTrace, you were blocking your own grips by doing that.


        Consider supporting me on patreon

        My Open source tools and plugins
        Advanced Sessions Plugin
        VR Expansion Plugin

        Comment


          mordentral

          Thank you. I am slowly working out these little confusions.

          I got another one for you... Is there a way to limit the player to only two locomotion types? I would like them to only be able to choose between Armswing or Teleport. I have tried removing the other ones from the "Movement Mode Enumeration" but ended up with tons of errors. Clearly, that cannot be the correct way. :P

          Comment


            Hey, thanks a lot for the reply even though you're so busy.
            Originally posted by mordentral View Post
            I doubt you were on the latest character anyway, it isn't Master it is still a beta branch.
            I initially built the latest master cl and just updated the closest grip nodes (in my old modified 4.17 template character) that were erring out. Was getting crashes so then I tried the latest char. movement refactor cl. Sorry, I wrongfully assumed that the movement improvements were happening on the backend, not in BP... What I should have said was that I tried both master (4.18) and latest refactor (4.18), not the latest char. I apologize for that.

            Originally posted by mordentral View Post
            You didn't lose your calibration did you?
            I've no idea. Maybe. How does one lose calibration or check that it's been lost? I googled around for info on it but didn't find anything related.
            I'll try to run the Steam VR setup/calibration thing again. Thanks a lot for the help!

            Edit: It looks like it got fixed just by running the simple SteamVR stand-up calibration. Thank you so much for the heads-up! And sorry for posting it here.
            Last edited by kusokuso1; 11-08-2017, 05:25 AM.

            Comment


              AtmaStudios
              One way to toggle between your desired two movement modes (assuming you're using the VRExpTemplate character) is by slightly modifying the Cycle Movement Modes function in the Vive_PawnCharacter.

              I pm'd you a screenshot of a modified right hand movement mode select. That's the only modification I made. I left the enum as is. It just switches the mode to Armswing if the current mode is teleport, and to teleport if it's not teleport.

              Comment


                Originally posted by AtmaStudios View Post
                mordentral

                Thank you. I am slowly working out these little confusions.

                I got another one for you... Is there a way to limit the player to only two locomotion types? I would like them to only be able to choose between Armswing or Teleport. I have tried removing the other ones from the "Movement Mode Enumeration" but ended up with tons of errors. Clearly, that cannot be the correct way. :P
                Like Kuso said, you can modify the cycling, or just directly control it yourself and unlink the cycling all together. The latter would be better, the cycle is only there to demo in the template and you likely want the side grips for more in a normal game.

                LeftHandMovementMode and RightHandMovementMode enums are pretty much all you need to set to choose movement modes.


                Consider supporting me on patreon

                My Open source tools and plugins
                Advanced Sessions Plugin
                VR Expansion Plugin

                Comment


                  Hi guys,

                  Is there any way to disable / get additional control over the "VRWall Slide" / Repulsion mechanism in the VRMovementReference?

                  I'm looking to have a little more control over what happens when the character collides (mainly to minimize nauseating effects for first-time users). For now, I was thinking about using a teleport away from the Wall/Object..

                  One possibility is to use a non-VR character, but then I need to build the build the pawn all over again - and I lose the possibility to control in-game how collision is handled..

                  Thanks for your thoughts!
                  Warner



                  Comment


                    Originally posted by Warner V View Post
                    Hi guys,

                    Is there any way to disable / get additional control over the "VRWall Slide" / Repulsion mechanism in the VRMovementReference?

                    I'm looking to have a little more control over what happens when the character collides (mainly to minimize nauseating effects for first-time users). For now, I was thinking about using a teleport away from the Wall/Object..

                    One possibility is to use a non-VR character, but then I need to build the build the pawn all over again - and I lose the possibility to control in-game how collision is handled..

                    Thanks for your thoughts!
                    Warner
                    Well you can always change the walls to overlap and do whatever you want with it then...... There is also walking collision override for the root capsule which lets you only have wall collision during locomotion but during walking without locomotion you can walk through / into the walls as it uses a separate collision channel with that enabled.

                    The upcoming 4.18 beta branch that overhauls the main character also adds events for when the wall sliding begins and ends to allow people to customize further as well (blanking vision, adding stable boundaries so that the slide doesn't feel personal, ect).

                    As far as disabling, you already have all of the control you need for that, the character follows all std engine collision protocol, I don't touch teleport back from penetration or other solutions like that as there are many ways to handle it and they don't fall into my ideal for the plugin.

                    Generally it isn't an issue unless you are having tables or blocking obstacles provide pushback, which I would suggest be avoided. Really only walls should be doing that.


                    Consider supporting me on patreon

                    My Open source tools and plugins
                    Advanced Sessions Plugin
                    VR Expansion Plugin

                    Comment


                      Hey there,
                      we decided to implement this plugin for the vr networking in our already working project. We use the distance between the MotionControllers to set the WorldToMetersScale to scale us up and down. After implementing this plugin we have strange behaviour on this. When the controllers are close together (10cm) it works as it was previously. When the controllers are further away (~60cm) the controllers start to jitter horribly and the scaling goes back and forth what causes the jitter to accumulate into a complete mess. Moving the controllers close together causes the jitter to stop. When the scaling is initialized with the controllers far apart (>60cm) the jitter starts immediately, even when the controller are not moved.
                      So whatever state of scaling we are in: Controllers far apart = horrible jitter, close together = everything normal.
                      The MotionControllerComponent is within the PlayerCharacter. Everything attached to the Component is in its own blueprint (like the controller mesh).

                      Another very interesting part: Just adding a SkeletalMeshComponent as child to the GripMotionControllerComponent within the PlayerCharacter prevents the jitter, for what ever reason (it has to be a SkeletalMesh!). It even is enough to add just one SkeletalMesh to one GripMotionController to prevent the jitter on both controllers.

                      So it looks like it has something to do with the childs of the GripMotionControllers. I had a look in the code and found UGripMotionControllerComponent::FGripViewExtension::GatherLateUpdatePrimitives which gathers the whole child hirarchy of the GripMotionControllers and adds those to the LateUpdate stuff when a child component is a PrimitiveComponent. I put in a breakpoint at the beginning of the function, but it never fired. So the function seems not to be called at all what makes it even more strange.

                      What is this late update stuff? I came across it now multiple times, but could not find an direct explanation. In terms of Unity engine this seems to be a tick(?) that comes up last within the engine loop, just before rendering. In terms of Unreal this seems to be the TickGroup. Some more explanation about this would be nice.

                      Edit: Engine Version 4.16
                      Last edited by Rumbleball; 11-09-2017, 12:10 PM.
                      DebugWidget - Helper for debugging in VR
                      WidgetBox - Recycle your widgets the smart way
                      NotificationBackbone - Send notifications via Feeds
                      SteamWorkhop - Blueprint and Cpp
                      UnrealPluginBuilder - Package via Drag&Drop
                      RuntimeMeshImportExport - Sync and Async

                      Comment


                        Originally posted by Rumbleball View Post
                        Hey there,
                        we decided to implement this plugin for the vr networking in our already working project. We use the distance between the MotionControllers to set the WorldToMetersScale to scale us up and down. After implementing this plugin we have strange behaviour on this. When the controllers are close together (10cm) it works as it was previously. When the controllers are further away (~60cm) the controllers start to jitter horribly and the scaling goes back and forth what causes the jitter to accumulate into a complete mess. Moving the controllers close together causes the jitter to stop. When the scaling is initialized with the controllers far apart (>60cm) the jitter starts immediately, even when the controller are not moved.
                        So whatever state of scaling we are in: Controllers far apart = horrible jitter, close together = everything normal.
                        The MotionControllerComponent is within the PlayerCharacter. Everything attached to the Component is in its own blueprint (like the controller mesh).

                        Another very interesting part: Just adding a SkeletalMeshComponent as child to the GripMotionControllerComponent within the PlayerCharacter prevents the jitter, for what ever reason (it has to be a SkeletalMesh!). It even is enough to add just one SkeletalMesh to one GripMotionController to prevent the jitter on both controllers.

                        So it looks like it has something to do with the childs of the GripMotionControllers. I had a look in the code and found UGripMotionControllerComponent::FGripViewExtension::GatherLateUpdatePrimitives which gathers the whole child hirarchy of the GripMotionControllers and adds those to the LateUpdate stuff when a child component is a PrimitiveComponent. I put in a breakpoint at the beginning of the function, but it never fired. So the function seems not to be called at all what makes it even more strange.

                        What is this late update stuff? I came across it now multiple times, but could not find an direct explanation. In terms of Unity engine this seems to be a tick(?) that comes up last within the engine loop, just before rendering. In terms of Unreal this seems to be the TickGroup. Some more explanation about this would be nice.

                        Edit: Engine Version 4.16
                        UE4 gathers scene proxies and late updates them in the rendering thread by re-sampling the controller / HMD location there and applying the difference to their visual location (not game location) since the game thread last moved them. This is because the rendering thread is a frame or so after the game thread and you can get significant offset with fast movements in VR in that time.

                        Prior to 4.18 (.17 of my plugin because I implemented it early) they were using a method that caused some thread thrashing and jitter like what you were seeing. It mostly happened when moving at high velocities but I could see if happening with scaling the world as well.

                        TLDR: 4.17 of my plugin, or 4.18 of the engine likely fix this for you, it should be because of badly managed cross thread variables that they had in the late update system. However you can also just turn off late updates on the controllers during this scaling operation and it should also fix it.

                        I don't know if you had late updates off in your original controllers? They should be using the same logic for the late update as epics in the 4.16 branch. Its possible that there is something missed, but I just went back over some of those areas recently.


                        *Edit* I have it on my 4.18 list to run down through the world scaling again since they made changes to how the components handle it (post 4.16). I can probably take a look back at the older version too.
                        Last edited by mordentral; 11-09-2017, 12:28 PM.


                        Consider supporting me on patreon

                        My Open source tools and plugins
                        Advanced Sessions Plugin
                        VR Expansion Plugin

                        Comment


                          Originally posted by mordentral View Post

                          UE4 gathers scene proxies and late updates them in the rendering thread by re-sampling the controller / HMD location there and applying the difference to their visual location (not game location) since the game thread last moved them. This is because the rendering thread is a frame or so after the game thread and you can get significant offset with fast movements in VR in that time.

                          Prior to 4.18 (.17 of my plugin because I implemented it early) they were using a method that caused some thread thrashing and jitter like what you were seeing. It mostly happened when moving at high velocities but I could see if happening with scaling the world as well.

                          TLDR: 4.17 of my plugin, or 4.18 of the engine likely fix this for you, it should be because of badly managed cross thread variables that they had in the late update system. However you can also just turn off late updates on the controllers during this scaling operation and it should also fix it.

                          I don't know if you had late updates off in your original controllers? They should be using the same logic for the late update as epics in the 4.16 branch. Its possible that there is something missed, but I just went back over some of those areas recently.
                          Thanks for your fast reply.
                          Right now we can't upgrade as we rely on a plugin that is not up to date yet.
                          I tried calling SetGripLateUpdateSettings with "LateUpdatesAlwaysOff" but it did not fix it.

                          As you describe it the late update is just a rendering thing. If so, why does it seem to mess with the location values on the game thread?
                          DebugWidget - Helper for debugging in VR
                          WidgetBox - Recycle your widgets the smart way
                          NotificationBackbone - Send notifications via Feeds
                          SteamWorkhop - Blueprint and Cpp
                          UnrealPluginBuilder - Package via Drag&Drop
                          RuntimeMeshImportExport - Sync and Async

                          Comment


                            Originally posted by Rumbleball View Post

                            Thanks for your fast reply.
                            Right now we can't upgrade as we rely on a plugin that is not up to date yet.
                            I tried calling SetGripLateUpdateSettings with "LateUpdatesAlwaysOff" but it did not fix it.

                            As you describe it the late update is just a rendering thing. If so, why does it seem to mess with the location values on the game thread?
                            No turn the late updates off on the controllers themselves, also DOES it mess with their game thread values? You said that the hands were VISIBLY shaking, I would assume that if the game thread values were off that the scaling would shake as well.

                            Because that would be an entirely different thing.

                            *Edit* Just saw you say that the scaling goes back and forth..mmmm


                            Are you using the simple character? The code base is the exact same for the controllers between epics and mine EXCEPT for when using a simple character as I have to pull back the controllers in that case.
                            Last edited by mordentral; 11-09-2017, 01:31 PM.


                            Consider supporting me on patreon

                            My Open source tools and plugins
                            Advanced Sessions Plugin
                            VR Expansion Plugin

                            Comment


                              Originally posted by mordentral View Post

                              No turn the late updates off on the controllers themselves, also DOES it mess with their game thread values? You said that the hands were VISIBLY shaking, I would assume that if the game thread values were off that the scaling would shake as well.

                              Because that would be an entirely different thing.

                              *Edit* Just saw you say that the scaling goes back and forth..mmmm


                              Are you using the simple character? The code base is the exact same for the controllers between epics and mine EXCEPT for when using a simple character as I have to pull back the controllers in that case.
                              I'm using the AVRBaseCharacter. Only thing I'm doing is I have a child of AVRBaseCharacter that Destroys the controllers and replaces them with a child of GripMotionController (doing that in the constructor). Those child controllers just override TickGrip witch I made virtual. I don't want TickGrip to be called, as we don't use the grip stuff and there seems to be a lot of code in.
                              As everything is working when attaching a SkeletalComponent to the controllers, I assume I did nothing wrong there.

                              Flying:
                              We also need to fly the whole time of the game in multiplayer. However I'm not able to get the clients to "fly". They are always falling down. I try setting SetMovementMode and SetReplicatedMovementMode on server and client to "flying"

                              Edit: Was a bit to fast. Managed to make the Clients "fly" but for now they are always reset by the server. Will have another look tomorrow.
                              Last edited by Rumbleball; 11-09-2017, 07:10 PM.
                              DebugWidget - Helper for debugging in VR
                              WidgetBox - Recycle your widgets the smart way
                              NotificationBackbone - Send notifications via Feeds
                              SteamWorkhop - Blueprint and Cpp
                              UnrealPluginBuilder - Package via Drag&Drop
                              RuntimeMeshImportExport - Sync and Async

                              Comment


                                Originally posted by Rumbleball View Post

                                I'm using the AVRBaseCharacter. Only thing I'm doing is I have a child of AVRBaseCharacter that Destroys the controllers and replaces them with a child of GripMotionController (doing that in the constructor). Those child controllers just override TickGrip witch I made virtual. I don't want TickGrip to be called, as we don't use the grip stuff and there seems to be a lot of code in.
                                As everything is working when attaching a SkeletalComponent to the controllers, I assume I did nothing wrong there.

                                Flying:
                                We also need to fly the whole time of the game in multiplayer. However I'm not able to get the clients to "fly". They are always falling down. I try setting SetMovementMode and SetReplicatedMovementMode on server and client to "flying"

                                Edit: Was a bit to fast. Managed to make the Clients "fly" but for now they are always reset by the server. Will have another look tomorrow.
                                Base character is just a proxy between the two different characters so that I can reduce code duplication (climbing and special flags that both need), it isn't a fully functional VR character in itself.....

                                Also TickGrip only does things when there are gripped objects, having no gripped objects it early's out of the loops and only does two transform Gets. If you are making a child of the original controllers you will also want to be totally sure that you aren't calling Super::TickComponent or you will start getting weird issues.


                                *Edit* I'll note that while looking into the world scale thing today I didn't find any issue with that hitch on 4.18, however I did find that Epics new late update system screws over the motion controllers location if the world scale is not 100.0f.
                                Last edited by mordentral; 11-09-2017, 09:52 PM.


                                Consider supporting me on patreon

                                My Open source tools and plugins
                                Advanced Sessions Plugin
                                VR Expansion Plugin

                                Comment

                                Working...
                                X