Add support for "none" controller mode: unplug virtual joystick and allow alternative controllers

This commit is contained in:
iChris4 committed 2026-09-26 21:53:48 +02:00
1 parent 171702bef4
commit c536f0087d
12 files changed
+212 -120

No files matched your search

@@ -302,7 +302,7 @@ class SettingsPage(
section(R.string.section_controls) {
choice(
R.string.controls_mode, R.string.controls_mode_helper,
listOf(R.string.controls_mode_wii_remote, R.string.controls_mode_gamepad),
listOf(R.string.controls_mode_wii_remote, R.string.controls_mode_gamepad, R.string.controls_mode_none),
read = { stringIndex(it, "vr", "controller_mode", CONTROLLER_MODES) },
write = { c, index -> c.setString("vr", "controller_mode", CONTROLLER_MODES[index]) },
)
@@ -316,7 +316,7 @@ class SettingsPage(
info(R.string.controls_map_a, activity.getString(R.string.controls_map_a_value))
info(R.string.controls_map_b, activity.getString(R.string.controls_map_b_value))
info(R.string.controls_map_12, activity.getString(R.string.controls_map_12_value))
info(R.string.controls_map_minus_plus, activity.getString(R.string.controls_map_minus_plus_value))
info(R.string.controls_map_plus, activity.getString(R.string.controls_map_plus_value))
info(R.string.controls_map_stick, activity.getString(R.string.controls_map_stick_value))
info(R.string.controls_map_z, activity.getString(R.string.controls_map_z_value))
info(R.string.controls_map_c, activity.getString(R.string.controls_map_c_value))
@@ -759,7 +759,7 @@ class SettingsPage(
val PERFORMANCE_LEVELS = listOf("boost", "sustained_high", "sustained_low", "power_savings", "default")
// runtime_config.h's kVrFoveationLevels, the default ("off") first.
val FOVEATION_LEVELS = listOf("off", "low", "medium", "high")
val CONTROLLER_MODES = listOf("wii_remote", "gamepad")
val CONTROLLER_MODES = listOf("wii_remote", "gamepad", "none")
val INTERPOLATION_FPS = listOf(0L, 1L, 72L, 90L, 120L)
val RESOLUTIONS = listOf(1.0, 1.5, 2.0, 3.0, 4.0)
val SUPPORTED_RESOLUTIONS = listOf(0.0, 1.0, 1.5, 2.0, 3.0, 4.0, 6.0, 8.0)
+4 -3
View File
@@ -588,9 +588,10 @@
<!-- Controls tab -->
<string name="section_controls">Controllers</string>
<string name="controls_mode">VR controllers</string>
<string name="controls_mode_helper">What the Touch controllers are to the game.</string>
<string name="controls_mode_helper">What the Touch controllers are to the game. None leaves it to another controller, such as a Bluetooth gamepad; left Y still opens the settings panel.</string>
<string name="controls_mode_wii_remote">Wii Remote + Nunchuk</string>
<string name="controls_mode_gamepad">Gamepad</string>
<string name="controls_mode_none">None</string>
<string name="controls_rumble">Vibration</string>
<string name="controls_rumble_helper">The game\'s rumble vibrates the controllers.</string>
<string name="section_controls_mapping">Wii Remote + Nunchuk buttons</string>
@@ -600,8 +601,8 @@
<string name="controls_map_b_value">Right trigger</string>
<string name="controls_map_12">1 / 2</string>
<string name="controls_map_12_value">Right stick up / down</string>
<string name="controls_map_minus_plus">− / +</string>
<string name="controls_map_minus_plus_value">Left X / left menu</string>
<string name="controls_map_plus">+</string>
<string name="controls_map_plus_value">Left X or left menu</string>
<string name="controls_map_stick">Nunchuk stick</string>
<string name="controls_map_stick_value">Left stick</string>
<string name="controls_map_z">Z</string>