Search Issue Tracker
Fixed in 0.3.0-preview
Votes
1
Found in [Package]
0.2.6-preview
Issue ID
1140861
Regression
Yes
[Scripting] Input Action loses callback functions after re-enabled.
GitHub: https://github.com/Unity-Technologies/InputSystem/issues/472
https://github.com/Unity-Technologies/InputSystem/issues/538
Repro:
1. Download attached asset package "EnableTest"
2. Download package and project at: https://github.com/Unity-Technologies/InputSystem
3. Use existing scene or create a new one, import the asset package into the project
4. Attach the C# script "EnableEventTest" to any gameobject, then attach InputAction, "TestControls", to the script
5. Enter Play Mode
6. Press 1 on keyboard, and some messages appear in the Console
7. Press 2, and the Action for 1 is disabled. Press 2 again to re-enable the 1 Action.
8. Press 1 now
Actual: The callback function bond to Input Action is lost after the Action is disabled and re-enabled again.
Note: In the C# script "EnableEventTest", "OnSecondPerformed" function, un-comment the three lines of code. This will rebind the callback functions to the first action before it is re-enabled. But they still won't be fired.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- OnPostprocessAllAssets() is not called for a modified Prefab when another Asset is set Dirty in the same callback
- [Android] UIToolkit ClickEvent is fired when the device is rotated
- Compilation errors occur when "uintBitsToFloat(int)" gets used in OpenGLES
- User Reporting does not send reports when Managed Stripping Level is set to Low or higher
- Editor crashes and a window with "GetManagerFromContext: pointer to object of manager 'MonoManager' is NULL (table index 5)" error is thrown when launching a project with a corrupted library
Add comment