Forum Discussion
dustums
10 years agoHonored Guest
Potential Bug in OVRPlayerController.cs (0.6)
I was monkeying around in OVRPlayerController to get it to work in both VR and non-VR mode, and I believe I've found a bug in the code.
Line 248 reads:
which is used to scale the inputs independent of frame rate.
Later at line 301, the controller axis inputs are scaled using a moveInfluence of:
This scales by SimulationRate * Time.deltaTime twice, which I believe mucks up the frame rate independence. Higher frame rates slow down player movement. I believe the line should read:
Can anyone verify my thinking? Thanks.
Line 248 reads:
MoveScale *= SimulationRate * Time.deltaTime;
which is used to scale the inputs independent of frame rate.
Later at line 301, the controller axis inputs are scaled using a moveInfluence of:
moveInfluence = SimulationRate * Time.deltaTime * Acceleration * 0.1f * MoveScale * MoveScaleMultiplier;
This scales by SimulationRate * Time.deltaTime twice, which I believe mucks up the frame rate independence. Higher frame rates slow down player movement. I believe the line should read:
moveInfluence = Acceleration * 0.1f * MoveScale * MoveScaleMultiplier;
Can anyone verify my thinking? Thanks.
Replies have been turned off for this discussion
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 7 years ago
- 10 years ago
- 10 years ago