Aloow Slidey Movement Toggle

Remove's acceleration which could be a cause of motion sickness
This commit is contained in:
Simon 2020-05-27 18:09:59 +01:00
parent 649d27c982
commit 2eb41c6246
3 changed files with 15 additions and 1 deletions

View File

@ -2314,12 +2314,13 @@ OptionMenu VROptionsMenu protected
Option "Two Handed Weapons", "vr_two_handed_weapons", "OnOff"
Option "Off-hand Move Direction", "vr_move_use_offhand", "OffOn"
StaticText ""
StaticText "Set Snap-Turn to < 10 for Smooth Turn"
StaticText "Set Snap-Turn to <= 10 degrees for \"Smooth\" Turn"
Slider "Snap-turn Angle", "vr_snapTurn", 0.0, 90.0, 1.0, 2
StaticText ""
StaticText "Locomotion"
Option "Use Teleport", "vr_teleport", "OnOff"
Option "Allow slidey movement (Momentum)", "vr_momentum", "OnOff"
Slider "Walking Speed", "vr_move_speed", 5, 50, 1, 2
Slider "Run Multiplier", "vr_run_multiplier", 0.0, 5.0, 0.1, 2

View File

@ -138,6 +138,19 @@ class PlayerPawn : Actor
if (health > 0) Height = FullHeight;
}
Super.Tick();
//Taken from the Wolf-3D TC - Prevent player having momentum/acceleration to avoid puking
CVar vr_momentum = CVar.FindCVar("vr_momentum");
if ((!vr_momentum || !vr_momentum.GetInt()) && pos.z == floorz)
{
vel *= 0;
Speed = Default.Speed * 8;
}
else
{
Speed = Default.Speed;
}
}
//===========================================================================

Binary file not shown.