Page MenuHome
Paste P2655

VR fly mod (analog thumbstick)
ActivePublic

Authored by Peter Kim (muxed-reality) on Dec 10 2021, 8:59 AM.
diff --git a/viewport_vr_preview/configs/default.py b/viewport_vr_preview/configs/default.py
index a20c5c6d..c0acbaae 100644
--- a/viewport_vr_preview/configs/default.py
+++ b/viewport_vr_preview/configs/default.py
@@ -67,6 +67,10 @@ actionconfig_data = \
{"op_properties":
[("mode", 'VIEWER_FORWARD'),
("lock_location_z", True),
+ ("speed_min", 0.006),
+ ("speed_max", 0.054),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -84,6 +88,10 @@ actionconfig_data = \
{"op_properties":
[("mode", 'VIEWER_BACK'),
("lock_location_z", True),
+ ("speed_min", 0.006),
+ ("speed_max", 0.054),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -101,6 +109,10 @@ actionconfig_data = \
{"op_properties":
[("mode", 'VIEWER_LEFT'),
("lock_location_z", True),
+ ("speed_min", 0.006),
+ ("speed_max", 0.054),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -118,6 +130,10 @@ actionconfig_data = \
{"op_properties":
[("mode", 'VIEWER_RIGHT'),
("lock_location_z", True),
+ ("speed_min", 0.006),
+ ("speed_max", 0.054),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -134,8 +150,10 @@ actionconfig_data = \
("fly_up", {"type": 'FLOAT', "user_path0": '/user/hand/right', "user_path1": '', "op": 'wm.xr_navigation_fly', "op_mode": 'MODAL', "bimanual": 'False', "haptic_name": '', "haptic_match_user_paths": 'False', "haptic_duration": '0.0', "haptic_frequency": '0.0', "haptic_amplitude": '0.0', "haptic_mode": 'PRESS'},
{"op_properties":
[("mode", 'UP'),
- ("speed_min", 0.014),
+ ("speed_min", 0.007),
("speed_max", 0.042),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -152,8 +170,10 @@ actionconfig_data = \
("fly_down", {"type": 'FLOAT', "user_path0": '/user/hand/right', "user_path1": '', "op": 'wm.xr_navigation_fly', "op_mode": 'MODAL', "bimanual": 'False', "haptic_name": '', "haptic_match_user_paths": 'False', "haptic_duration": '0.0', "haptic_frequency": '0.0', "haptic_amplitude": '0.0', "haptic_mode": 'PRESS'},
{"op_properties":
[("mode", 'DOWN'),
- ("speed_min", 0.014),
+ ("speed_min", 0.007),
("speed_max", 0.042),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -170,8 +190,10 @@ actionconfig_data = \
("fly_turnleft", {"type": 'FLOAT', "user_path0": '/user/hand/right', "user_path1": '', "op": 'wm.xr_navigation_fly', "op_mode": 'MODAL', "bimanual": 'False', "haptic_name": '', "haptic_match_user_paths": 'False', "haptic_duration": '0.0', "haptic_frequency": '0.0', "haptic_amplitude": '0.0', "haptic_mode": 'PRESS'},
{"op_properties":
[("mode", 'TURNLEFT'),
- ("speed_min", 0.01),
+ ("speed_min", 0.005),
("speed_max", 0.03),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":
@@ -188,8 +210,10 @@ actionconfig_data = \
("fly_turnright", {"type": 'FLOAT', "user_path0": '/user/hand/right', "user_path1": '', "op": 'wm.xr_navigation_fly', "op_mode": 'MODAL', "bimanual": 'False', "haptic_name": '', "haptic_match_user_paths": 'False', "haptic_duration": '0.0', "haptic_frequency": '0.0', "haptic_amplitude": '0.0', "haptic_mode": 'PRESS'},
{"op_properties":
[("mode", 'TURNRIGHT'),
- ("speed_min", 0.01),
+ ("speed_min", 0.005),
("speed_max", 0.03),
+ ("speed_interpolation0", (0.25, 0.1)),
+ ("speed_interpolation1", (0.75, 0.5)),
],
},
{"bindings":

Event Timeline