Announcement

Collapse
No announcement yet.

VR Expansion Plugin

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

    How can I setup the level blueprint such that it starts the level with the pawn on a car?

    Comment


      Originally posted by Adler Alonso View Post
      How can I setup the level blueprint such that it starts the level with the pawn on a car?
      Do you even need a full pawn? Or is it just a racing game?

      If you need a full pawn then use the SetSeatedMode on load on the car.


      Consider supporting me on patreon

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

      Comment


        Hi mordentral and other developers-

        I've been exploring using this tool for a game I'm currently working on in VR. It's our first VR experience, but we've run into a sort of roadblock. Our game requires us to have a pawn with a single skeletal mesh that can be manipulated via the HMD and the motion controllers. It seems like the VRSimpleCharacter is exactly what we've need, and I've implemented some IK logic in the mannequin included with the third person template that works for movement. We have a fairly significant problem, however.

        I added my VRSimpleCharacter to the project, gave it a mesh attached to the camera, and dropped it into the world with updated animation blueprints. However, the camera it uses is not the camera attached to the pawn, but rather a different camera that can be controlled with the arrow keys. When I went to fix this by adding a gamemode and changing to the included player controller and everything, my camera worked but suddenly my mesh was broken. Are there any available examples of characters built with this plugin that have this sort of movement- one skeletal mesh attached to all three control points?

        I tried looking through the wiki but couldn't find anything. I'm somewhat of a novice at all of this so I apologize if someone has already asked this or if my question has an easy solution.

        Comment


          Hi Mordentral, thank you again for the plugins and example project.

          I've attempted to package your example project in 4.20 but unfortunately received errors when I try to package with 'cook only maps' unchecked in the project settings (log is attached). However when 'cook only maps' is checked, package is a success.

          What could be the issue here? Hoping to be able to get a package out with the setting unchecked. Any help would be appreciated!
          Attached Files

          Comment


            Originally posted by slam937 View Post
            Hi Mordentral, thank you again for the plugins and example project.

            I've attempted to package your example project in 4.20 but unfortunately received errors when I try to package with 'cook only maps' unchecked in the project settings (log is attached). However when 'cook only maps' is checked, package is a success.

            What could be the issue here? Hoping to be able to get a package out with the setting unchecked. Any help would be appreciated!
            Assertion failed: !PinRef->bWasTrashed is a common and re-occuring assertion on packaging since engine version 4.15 or so. There are multiple bug reports with fixes committed for different variations of it. Congratulations you found another one! It appears to be a stale trace pin somewhere in the blueprints where it doesn't know what kind of trace it is doing, there are no hints of exactly where but if I get time tonight i'll try to load the engine with debug symbols and track down the name. It may be in old content imported from the original Epic template that I didn't delete since its obviously something that is never used in the maps.

            Originally posted by Tomo Kunagisa View Post
            Hi mordentral and other developers-

            I've been exploring using this tool for a game I'm currently working on in VR. It's our first VR experience, but we've run into a sort of roadblock. Our game requires us to have a pawn with a single skeletal mesh that can be manipulated via the HMD and the motion controllers. It seems like the VRSimpleCharacter is exactly what we've need, and I've implemented some IK logic in the mannequin included with the third person template that works for movement. We have a fairly significant problem, however.

            I added my VRSimpleCharacter to the project, gave it a mesh attached to the camera, and dropped it into the world with updated animation blueprints. However, the camera it uses is not the camera attached to the pawn, but rather a different camera that can be controlled with the arrow keys. When I went to fix this by adding a gamemode and changing to the included player controller and everything, my camera worked but suddenly my mesh was broken. Are there any available examples of characters built with this plugin that have this sort of movement- one skeletal mesh attached to all three control points?

            I tried looking through the wiki but couldn't find anything. I'm somewhat of a novice at all of this so I apologize if someone has already asked this or if my question has an easy solution.

            Yes it is very common to run an IK skeletal mesh on the two different characters, I can't comment on specifically what is going wrong with yours since "it breaks" isn't very descriptive and its just down to whatever logic you implemented for your IK. I'll note that while I have the simple character move with the HMD linearly, I do not have it follow in rotation, so if you want the mesh to auto rotate with the HMD you will need to attach it to the ParentRelativeComponent. That is the main difference between the simple character and the full one, the simple one moves with the HMD while the full one does not and retains the default offset.

            Your first issue was that you were controlling the wrong pawn (your gamemode was setup incorrectly), as for the plugins player controller class, while I suggest using it since it provides a couple of extra features and allows the navigation movement, it isn't required to actually use the characters.



            Consider supporting me on patreon

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

            Comment


              Originally posted by slam937 View Post
              Hi Mordentral, thank you again for the plugins and example project.

              I've attempted to package your example project in 4.20 but unfortunately received errors when I try to package with 'cook only maps' unchecked in the project settings (log is attached). However when 'cook only maps' is checked, package is a success.

              What could be the issue here? Hoping to be able to get a package out with the setting unchecked. Any help would be appreciated!
              Found it, Delete the following blueprint (I deleted it going forward in the template): Content/VRExpansion/Vive/Testing/PlanerLock

              Its a corrupt blueprint, its not a very useful tutorial item so just deleting it is fine.

              *Edit* Also had to make a small edit to the non networked character just refreshing a node.
              Last edited by mordentral; 08-21-2018, 10:52 AM.


              Consider supporting me on patreon

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

              Comment


                Originally posted by mordentral View Post

                You can, it sounds like like you have improper collision on it or something went wrong with your conversion. You can spawn a GrippableSkeletalMeshActor and use that instead with your original skeletal mesh.
                im completely confused on the process of bringing a gun into the game and dont understand the process. I cant follow any tutorials because your plugin is different.

                is there anyway to just use to gun base you made and just change the mesh picture? im trying to have less problems, and I thought I could but no matter what I do the gun loses all its features once the mesh is changed which I think its strange because its not changing the code. for example with your gun base, if I click and pick up the weapon with left mouse and let go of left mouse, your gun stays, with my simple mesh change the gunbase you made loses all its features.

                I spawned a GrippableSkeletalMeshActor and it to loses all its features, I can grip it but then when I let go of left mouse it doesnt stay in my hand like your base gun. it just drops to the floor and keeps on rolling and rolling and rolling. yet when I hit play it floats until I pick it up, and if dropped keeps rolling.

                do you have any videos on how to properly bring in a gun into the VR world and keep its settings?

                Comment


                  Thank you very much for your quick response!

                  It breaks was perhaps the wrong way to put it. When I added a gamemode and had the player spawn off of a VRPlayer Start, the mesh became offset, the camera was looking out of approximately the center of the mesh, and the arms were no longer moving around with the motion controller properly. I believe it has something to do with where my mesh is placed relative to the HMD's position. Is there a specific way I should be attaching it to the ParentRelativeComponent? Or will I need to find the offset myself when adding the mesh to the character?

                  The strange thing is that when there is no gamemode, the HMD and motion controllers move the character properly and the hands move to the proper side of the character. When the gamemode is added, even a BaseGamemode that's been extended and uses the right pawn (I think), the arms no longer translate properly with movement. The head still follows the proper rotation. I think this means that the HMD is in a different position relative to where it originally was?

                  Is there an example character in the template that uses a single skeletal mesh with a VRCharacter I could take a look at? Apologies for the rambling question.

                  Comment


                    Originally posted by PRESSURE2000 View Post

                    im completely confused on the process of bringing a gun into the game and dont understand the process. I cant follow any tutorials because your plugin is different.

                    is there anyway to just use to gun base you made and just change the mesh picture? im trying to have less problems, and I thought I could but no matter what I do the gun loses all its features once the mesh is changed which I think its strange because its not changing the code. for example with your gun base, if I click and pick up the weapon with left mouse and let go of left mouse, your gun stays, with my simple mesh change the gunbase you made loses all its features.

                    I spawned a GrippableSkeletalMeshActor and it to loses all its features, I can grip it but then when I let go of left mouse it doesnt stay in my hand like your base gun. it just drops to the floor and keeps on rolling and rolling and rolling. yet when I hit play it floats until I pick it up, and if dropped keeps rolling.

                    do you have any videos on how to properly bring in a gun into the VR world and keep its settings?
                    Sounds more like you have bad collision on it, just switching the static mesh on the weapon shouldn't have any different effects. Literally clicking on the static mesh in the actor and changing the mesh it references should work fine. When you convert from skeletal to static it likely doesn't have any collision then, you need to generate some for your model.


                    As for a standard GrippableSkeletal, no it wouldn't behave like that, the gun is customized with the settings it uses to behave how it does, you would have to copy the gameplay tags and setup it uses into any new grippable you want to copy it. The GameplayTags in the template for grippables define what buttons grip and release it and how, in a normal game these wouldn't exist but they are there in the template for maximum flexibility and to allow me to demo all of the different features.

                    *Edit* Oh, you will also need some Sockets on the new mesh if you intend to use the exact same gripping logic (snap to handle, ect), look in the mesh for the template gun and copy over the named sockets in there to where you would like them on the new gun. For advanced users you can switch to components and the like as well but generally the socket method is the most flexible.
                    Last edited by mordentral; 08-22-2018, 08:35 AM.


                    Consider supporting me on patreon

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

                    Comment


                      Originally posted by Tomo Kunagisa View Post
                      Thank you very much for your quick response!

                      It breaks was perhaps the wrong way to put it. When I added a gamemode and had the player spawn off of a VRPlayer Start, the mesh became offset, the camera was looking out of approximately the center of the mesh, and the arms were no longer moving around with the motion controller properly. I believe it has something to do with where my mesh is placed relative to the HMD's position. Is there a specific way I should be attaching it to the ParentRelativeComponent? Or will I need to find the offset myself when adding the mesh to the character?

                      The strange thing is that when there is no gamemode, the HMD and motion controllers move the character properly and the hands move to the proper side of the character. When the gamemode is added, even a BaseGamemode that's been extended and uses the right pawn (I think), the arms no longer translate properly with movement. The head still follows the proper rotation. I think this means that the HMD is in a different position relative to where it originally was?

                      Is there an example character in the template that uses a single skeletal mesh with a VRCharacter I could take a look at? Apologies for the rambling question.
                      You aren't using the correct pawn if the camera is waist height to begin with / you haven't started up VR mode correctly. If you want head locked VR you need to change the cameras position (change NetSmoother height), if you want roomscale you need to set the VR mode to roomscale and then that simple character should just work.

                      Sounds like you have the VR mode set to Eye Level to be honest which none of my default setup is made for, its easily possible to use that mode, but there is less reason to since the main point of the characters are the room scale movement being tied into their actions.

                      *Edit* I guess you could argue that the networked snap turning and climbing are reason enough to use a non standard character for head locked VR.

                      Regardless, when you changed game mode you were no longer initializing VR correctly.



                      As for the Parent Relative Attachment, it is by default locked to the head position for chests and inventories and waists and the like, you can set a bool on it to lock to the foot position instead which is generally better for being the parent of a SkeletalMesh body.

                      Also no, I don't have a full IK example in the template, to do it "correctly" would involve forcing a third party plugin or coding custom IK, neither of which I am willing to do for it. The default in engine IK setup is not good enough for a decent full body rig in VR, there are many third party solutions now that perform well so I point people to them when asked instead (leave that up to the specialists).
                      Last edited by mordentral; 08-21-2018, 11:51 PM.


                      Consider supporting me on patreon

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

                      Comment


                        Thanks again. I think that's the issue, I didn't set VR mode properly. I'll fix that and get everything working. I think the eye level setup was a remnant of some previous work we did in the same project with Vive specific setups.

                        I'll also take a look at the full body VR rig solutions. Sorry for so many dumb questions, thank you so much!

                        Comment


                          Sorry for the double post, but wanted to follow up:

                          Setting the VR Mode and changing around the values you suggested worked perfectly! The character is now running around and has its arms moving no problem. We also found that part of the problem was that there were two pawns being spawned, one ending up below the world for some strange reason. After deleting that, it solved the IK problem immediately.

                          We actually found that the problem was that we never set the VR Tracking Origin and it was set to floor level by default- we're using a Vive, so we needed it to be Eye Level. By combining all these fixes, we have a working character with arm IK. Thank you so much for all your help, I really appreciate it!

                          Comment


                            Originally posted by Tomo Kunagisa View Post
                            Sorry for the double post, but wanted to follow up:

                            Setting the VR Mode and changing around the values you suggested worked perfectly! The character is now running around and has its arms moving no problem. We also found that part of the problem was that there were two pawns being spawned, one ending up below the world for some strange reason. After deleting that, it solved the IK problem immediately.

                            We actually found that the problem was that we never set the VR Tracking Origin and it was set to floor level by default- we're using a Vive, so we needed it to be Eye Level. By combining all these fixes, we have a working character with arm IK. Thank you so much for all your help, I really appreciate it!
                            Eye level is the incorrect one actually if you want to retain room 1:1 and camera height, floor level is what you would normally want with a Vive unless you are sitting down.

                            It will work if you offset the camera of course, but you sacrifice 1:1 height with the tracked space.


                            Consider supporting me on patreon

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

                            Comment


                              Pushed a new commit to both repositories (for 4.20), pre-compiled binaries will be generated tonight since 4.20.2 just came out.

                              Plugin
                              Code:
                              Added GripScripts fully into the master branch with four reference c++ implementations
                              GS_Default (default gripping logic)
                              GS_LerpToHand (lerp initial grips to the hand)
                              GS_InteractibleSettings (Functions like the removed InteractibleSettings options)
                              GS_GunTools ( Currently unfinished set of tools for advanced gun interactions)
                              
                              Removed rollback on custom movement modes
                              This is to remove "climbing mode" hanging in place and seated mode issues.
                              Really only an issue in really high packet loss situations, but wanted to cover it.
                              
                              Also added a GetReplicatedMovementMode function that returns the current Conjoined movement
                              mode.
                              
                              Set OnClimbingSteppedUp to a BlueprintNativeEvent so that c++ users could use it.
                              
                              Set GetOpenVRModelAndTexture node to not fail out if a texture is missing and to just pass out a nullptr now.
                              It was failing on Knuckles Left controllers as they are missing a texure in full model mode from the OpenVR
                              RenderModels api.
                              
                              Corrected an oversight with the new OnDropped event on the motion controllers having a possibly stale variable (thanks SlimeQ)
                              Template
                              Code:
                              Re-wrote how the character / player controller is initialized to be far cleaner.
                              
                              Added Knuckles EV2 default controller profile and changed some of the character logic to check for it in OpenVR.
                              
                              Changed the FPS test pawn to load its profile in a different area
                              
                              Removed a corrupt BP and prepped everything so that packaging with PackageAllDirectorys works without issues on the template.
                              
                              Removed unused content that was just bloating the repository (left over EpicVR template content)
                              
                              Reference BP Grip script will be coming later.
                              
                              Changed Sedan actor to use a Boxmesh around it for the navigation modifier.
                              Last edited by mordentral; 08-22-2018, 03:15 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

                                Do you even need a full pawn? Or is it just a racing game?

                                If you need a full pawn then use the SetSeatedMode on load on the car.
                                Thanks for that. I see the event on the sedanBP but shall I start it from the levelBP referencing both the car and my character so I can pass the info the function needs?

                                Also, not sure if there is an example video of how to setup a socket grippable like for example, a bow (So the controller automatically sets the location on the center of the bow with the apropiate rotation. Like the gun for example.

                                Comment

                                Working...
                                X