VR-Ready C++/Blueprintable Pawn with common VR functions. Also good as a SteamVR project template.

https://forums.unrealengine.com/unreal-engine/feedback-for-epic/108461-ue4-4-15-has-been-giving-me-this-error-in-everything-so-far

Thats fantastic, it fixed the problem. but now my player starts too far from the point where i want it to start from. the player start is located in the right position and it plays fine in the engine but in the build it moves it too far. any idea how to solve that problem?

Regarding the initial spawn position, not sure if you’re describing the expected behavior – Player start is where the pawn spawns but if your headset is away from the center of your play area, then you are offset from the spawn location by how much your headset is away from the center of your defined playspace… This is as users may have their headsets out of their play area when starting a game (e.g. at their desk), and should be something you should cater for in your game/experience. If you want to “force” a repositioning of your level after pawn spawn, you can use the following node at the Pawn’s Begin Play event:

Hope that helps.

Cheers.

Thanks for the help runeberg, but unfortunately nothing is solving this problem. it always starts far from the player start position, it always starts near 0,0,0.

Does this happen in a completely empty level as well? Couple of things to check (if by “build” you mean packaged project, check Item 5 specifically the node combo I posted there):

  1. Check your GameMode if it’s pointing to the correct Pawn (VRPawn in this instance)
  2. Check your world settings for the level is pointing to the correct Gamemode
  3. Check if you have multiple player starts (or Pawn Actors) in the level
  4. Check for blocking collisions in your pawn mesh/es and the scene.
  5. Have a look at the notes in this post:
    https://forums.unrealengine.com/deve…20#post1390920
  6. If you are streaming levels, check Items 1 to 2 for your initial “main” persistent level, and items 3 to 4 for any other loaded level/s during game start.

Hope that helps.

unfortunately even in an empty level i have the same problem. i will try your other solutions.
p.s. i am using the pawn from your 04grab sample map.

For the demo project, levels were designed for the spawn point to be 0,0,0 (+ auto cam height offset)… if this is happening in an empty level, then definitely have a look at Items 1-3 closely in your project provided you are using the latest version of the plugin. You can also force a “respawn” at a different loc using the nodes I mentioned in Item 5, but in your case i reckon this should be your last recourse.

Also, if you haven’t yet, have a look at these vids which shows how to configure a VR level inluding Pawn starts using PlayerStart or a Pawn Actor:


lemme know.

So I decided to test it in a new project. So i first made a new first person project, then made a blank level and followed the youtube instruction, installed your plugin by copying the plugin folder into the project (Version - RunebergVRPlugin-4.16). made a new game mode “newVRgamemode” then right clicked on the RunebergVR_Pawn and created a blueprint class “newVRpawn” then went into the newVRgamemode and chose newVRpawn in pawn option. in the worldsetting i chose “newVRgamemode” and packaged the project. and still the same problem. the spawning is far from player start. :frowning: . i am sure i am doing something wrong.

Hi-- so this is only happening when you package and not during VR preview? Can you check your Default Game Map (not Editor) in Project Settings and see if it is pointing to the correct map? also, make sure you are running “Enable HMD” (https://docs.unrealengine.com/latest…lay/EnableHMD/), but guessing it is if you are in your HMD yet spawning in a different location.

Another thing, did you manage to try Item 5?

Otherwise, post a link to your test project here and I can have a quick look.

yes its only happening in the package and not vr preview in the editor, the default game map is set to the level i want to build, i can see all my level in the hmd but very far. i will try the point 5 and report back. will also try to upload the test project. thanks :slight_smile:

cool. lemme know, also make sure you are using the “Enable HMD” node somewhere in Begin play to make sure you are in VR Mode after packaging as otherwise you’d be in non VR Mode and could be also the reason why you’re perceiving that the camera is below where it should be; as out of the box, the plugin should have the camera offsets correctly for both the Vive & Rift with no modifs needed.

thanks, i tick “Start in VR” in Project Setting and it works in VR, earlier on i was indeed facing the problem that it wasnt starting in VR then I put console command “stereo on” in level blueprint, but now just “Start in VR”.

cool, yep the Project Settings tickbox defo way to go for pure VR projects, didnt realize it was already available in 4.16, the console command might be less useful/risky though in a shipping/non-development packaged build…

interesting you’re having issues only in a packaged build even when your start game map and gamemodes are all set accordingly even with an empty level, thinking this could just be a misconfig. When you get the chance, share the test project (empty level) and I can have a quick look at your setup as the respawn solution in Item 5 shouldnt really be necessary in your scenario. Also, would help if you post screenshots of your Map settings from Project Settings, Custom GameMode properties and World setting properties here.

Hi, So I tried the new project and i have to confess that it works fine and i was a little too hasty in assuming that its happening in new project as well, the camera was moving inside the floor and making it look blank, but it does not move far away. but in my old project the problem is still there. i have attached the screenshots of the project setting, worldsetting, pawn and gamemode settings.
thanks and regards

Hi-- no worries, it just helps in isolating the issue.

Since it is only happening on your level it does point to something there that’s possibly causing the Pawn to be pushed to a different location during spawn if this is indeed the issue. And as it is only happening in a packaged build, the likely culprit is something Physics-based in your level.

Therefore I suggest the following:

  1. Review the collision settings in your level and the meshes and any collision volumes in the pawn (including the root component), perhaps remove some actors one at a time that’s in or near the Pawn Spawn Location until you isolate the culprit.

  2. The fact that it is spawning “far away” may also mean it could be a large collision volume or encompassing actor in your level.

  3. The latest version of the VRPawn should already have this set but double check the following:

  • Pawn is set to “Spawn, Ignore Collisions”
  • Root mesh component (if unused) should have no collisions set
  • Check the Capsule Collision settings and see if it’s causing a block response to one of your actors in the level (also true for any mesh/es in the pawn)
  • Check Pawn is set to Auto-Possess the correct controller.
  1. Try putting the VRPawn as an actor directly (see 2nd video I posted in one of my previous responses) instead of using the Player Start approach. Take notice of a “Bad Size” indicator on the Pawn in the editor.

  2. Failing the above, you can try the Item 5 workaround I posted before, which causes a move of the Pawn after initial spawn, you can also put a slight delay to ensure the pawn moves properly-- this won’t help though if there’s something significant blocking the Pawn in your level.

I hope the above tips helps, otherwise, if you are willing to share your level, this is probably better posted in a more general area of this forum with a link to a copy of your project so others who are willing to investigate deeper can check for you if you are stuck. If you have access to UDN (Epic support) this is also a good thing to bring up to them.

Cheers and good luck!

So over the weekend I tried many things and nothing seemed to solve the problem. I have uploaded a project on dropbox, if you could please take a look. the level name is vive_test. it works fine in vr preview but gives me same problem with the build, it starts far from the player start. ive also tried using “stereo on” console command instead of checking VR box in setting just to make sure. but nothing works.
project link - Dropbox - File Deleted

Hi – Unfortunately the best I can do is provide you where you can look but since this is a highly project-specific issue, let’s hope someone form here would be willing to spend the time reviewing your project. I only do this under a paid consulting agreement.

I suggest cross-posting this as a more general forum post along with the specific things you’ve tried (feel free to re-use the lists I provided) and the corresponding results. Especially interesting would be the more recent results of slowly whittling down your scene to find the culprit actor/physics based BP, checking collision volumes or volume type actors and the Item 5 (post-spawn nodes / Game-Mode workaround).

Cheers and good luck!

Sure, I will try more to see where the problem lies.
p.s. its actually a brand new blank project with no files from my previous project and still the problem persist. i wonder if i have a problem with my vive setup.

Hi @VirtualSurrealism – Thanks for the clarification. I must’ve misunderstood you since you mentioned in one of your earlier posts that you tested with a blank level and that worked in a build you made.

Anyways, I had a quick look at the blank project you provided, looking at the runtime logs of the packaged project (in the Saved directory of the packaged project), the issue seems to be that the project library/plugin linking didnt work in the build as expected.

Interestingly though, I downloaded a fresh copy of the binaries from my GitHub repo and they seem to be OK for this project without any errors even with a packaged build (plus Item 5 solution should’ve still moved any pawn properly), it’s like there was a prior rebuild from your copy that didn’t have the “Runtime” property properly set in the uplugin file.

So you can either:

1. Redownload fresh copies of the binaries & source from GitHub
-or-
2. Recompile (convert project to C++, delete Binaries and Intermediate folders from within RunebergVR plugin subfolder)

If however you’re unable to properly recompile on your end (e.g. Dev PC not setup for UE4 C++ projects). In this case, I suggest you using the Marketplace version instead:

  1. Download the Marketplace version of the plugin
  2. Install the Plugin to Engine 4.16
  3. Delete the RunebergVR Plugin Source Code in the project (Plugins\RunebergVR) and Project\Binaries, Project\Build, Project\Intermediate and Project\Saved
  4. Open the project (you might get warnings)
  5. Enable RunbergVRPlugin from Settings > Plugins
  6. Restart the editor
  7. Rebuild the project

I strive to update 3 versions of the plugin (latest 3 versions of the Engine) in the Marketplace and they’re normally only a couple of days late than the GitHub version so unless you are using a C++ enabled project, the Marketplace version would be the most ideal version for you. Take note however, once 4.19 is out, future updates to 4.16, will be halted for both Marketplace & GitHub (although they wont be removed in the Marketplace but you do potentially miss out on new features and bug fixes).

Hope that helps.

Cheers.

**P.S: **When sharing UE projects to others in the future, you can also save some space by not including Intermediate, Build, Saved and Binaries (if not needed by the other party) directories.

Thanks for taking a look at the project :slight_smile: I will update you tomorrow regarding your suggestions. I did try downloading 4.18 and using your plugin’s 4.18 version but alas even there i faced the same problem, even with a new project.