Swing Arm locomotion - but no collision

Hey folks

i implemented a swing arm locomotion system into a scene im doing, it works perfectly fine but the issue im having is getting collisions to work.

This is the system i used

what i have done so far is I’ve added a collision box to different components to try and find out what the issue is, I’ve even added in the VR base pick up cube mesh and that responds to me walking into them, and so does the cable actors.

If anyone could help me on this that would be great - its a nice little movement system and id rather not step back to artificial locomotion

Cheers all!

The VR Pawn he is using in the tutorial is derived from the Pawn class. By default Pawn doesn’t have a collision capsule. You can either manually add a collision capsule as root of the Pawn or change the base class to Character, which will get an inherited collision capsule to it (plus an unused Movement Component). In this way the Pawn should be able to collide with other Actors in the scene, provided the collisions for both are setup properly (try with BlackAllDynamic).


I already answered by mistake with an old account, so you may get this twice… sorry about that.

The author of the tutorial uses a VR Pawn derived from the Pawn class. By default a Pawn doesn’t have any collision capsule nor a mesh which can collide with another actor. This is the reason why you don’t get any collision.

Mainly you have two ways to add collisions to your VR Pawn. 1) Manually add to it a collision capsule as root component or 2) edit its parent class and set it to Character. Characters have by default a collision capsule as root (plus a movement component which you won’t need here).

With that done, your Pawn should be able to collide with other actors in the scene which also have collisions enabled (something like Block All Dynamic for both should do the job). Give it a try and let us know here if you still have issues.


Brilliant cheers Marco

None of that will work…Character capsule as well as any additional root capsule you add is at the center of the play space (Actor 0,0,0). Tracked devices work off of the center location so if you are in roomscale and standing 5 feet to the side of center than your character “collision” will be 5 feet over from you. You also can’t move the root component without moving the actor itself (normally).

If you only want physics collision (objects being moved away from you) then you can enable collision on a capsule that you keep at the relative position of the HMD and that will work fine.

However if you want WORLD collision (you being blocked from movement by the world as well) then it gets more complicated.

You either need to:

Re position the collision to your HMD location (yaw locked component positioned with HMD) and manually sweep it with movements to limit distance / manually handle collision
(runebergs classes would likely be a good start to modify for this)

have a secondary character that follows along that you use to reign in the primary pawn
(this is being done by a few people with some references here in the forums)

re-code a pawn / character to work correctly with collision and VR
(there are examples and plugins for this).

None of the above, lots of people choose to darken vision / teleport out of penetration instead of hard block VR players or turn off movements / limit teleportation so that it accounts for the room space and doesn’t let them get farther than a wall (assuming they don’t walk outside of their configured roomscale…)

My understanding was that he just wanted to add collision to the Pawn itself (i.e. a collision capsule around it) and that this was Oculus specifc (so not really room scale but more in place movement). I know that what I had suggested works because I have implemented the same movement system in the past and have had the Pawn properly collide with other actors, so I am a bit puzzled by your statement “None of that will work…” Anyway, since you are the pro here, ubi maior minor cessat. :slight_smile:


Even if it is standing room only there will be an offset, but it would “sort” of work in that case (probably “good enough”).

Seeing as how he is talking about arm swing (touch controllers) the likely hood of it being a standing only experience is low as the default 3 camera setup with touch is roomscale and its likely it would want to be supported.

well, i do not understaтв the problem at all