Search Issue Tracker
By Design
Votes
0
Found in [Package]
1.14.0
Issue ID
ISXB-1507
Regression
Yes
Control Scheme does not change when simulating touch input
How to reproduce:
1. Open the “IN-98935_InputSystemTest“ project
2. Open the “SampleScene“
3. Select Windows → Analysis → Input Debugger → Options → Simulate Touch Input From Moue or Pen
4. Enter Play Mode and use the keyboard
5. In the Input Debugger, observe the Control Scheme at Users(1) → User #0
6. Click on the Game View with a mouse and observe the Control Scheme
Expected result: Control Scheme changes from “Keyboard&Mouse” to “Gamepad“
Actual result: The control Scheme remains “Keyboard&Mouse“
Reproducible with: 1.12.0 (6000.0.46f1), 1.14.0 (2021.3.50f1, 2022.3.61f1, 6000.0.46f1, 6000.1.0b14, 6000.2.0a8)
Not reproducible with: 1.11.2 (6000.0.46f1)
Reproducible on: Windows 10
Not reproducible on: No other environment tested
Notes: Sometimes the Control Scheme might be stuck at Gamepad (part of the issue)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
Resolution Note:
Based on the report, we're closing this as by design, but feel free to reopen if our assessment is incorrect.
The PR https://github.com/Unity-Technologies/InputSystem/pull/2023 introduced a fix to prevent constant switches between OnScreenControl devices and Pointer devices that interact with it.
Which means that only when the OnScreenControl device has any input event queued (through SendValueToControl(), for example), the control scheme will be switched. So you need to make sure your logic in UltimateTouchpad.cs deals with this, particularly in OnPointerDown/Up events. Those UI events are responsible for queuing input events which will change the active control scheme of PlayerInput.
Feel free to look at the implementations of OnScreenStick and OnScreenButton, and the OnScreenControlsSample that can be downloaded from the Package Manager > Input System package view.