Hey Everyone, I’ve been banging my head against a small issue lately. I’ve been experimenting with some physics-driven gameplay in VR. Physics substepping is awesome for this, as it has really made it easy to stabilize my simulation and keep things under control.
Unfortunately, I’ve run across what I think might be a bug related to it, since I can work around the issue when disabling physics substepping.
In my prototype right now, I have a cockpit that you sit in with a VR setup. So you can stay seated, then set the throttle, and the actor your VR origin is attached to will move forward. This is using the built-in player character class that ships with the engine.
After some acceleration, I noticed that the collision that drives the overlap for the motion controllers does not line up with the visuals for the hands. The position for the visuals seems to be correct, as I don’t see it sliding around if I hold my hand steady. The way I noticed it was I would set the throttle (a physical lever in the cockpit) then hold my hand steady behind it and continuously tap the trigger. Eventually, after gaining enough speed, I would grab hold of the throttle while my hand was a meter away from the handle.
Interestingly if I disable the rendering and show only collision for the motion controls, the debug renderer shows the collision sphere in the wrong place too. It will be lined up with the render mesh, and I will still be able to grab things in the scene while very far away from them.
When I go into project settings and disable physics substepping, this behavior goes away and I can grab things as normal.