damn i wanted to use both
I’m using both… left works for some reason, it’s the only one.
WASD works if you hold down all of the arrow keys at the same time. Perhaps someone confused || and &&
Still, very frustrating to ship a release, have my community file a bug, waste hours trying to find the issue, finally Google it to land here and see it has been known for a while yet there are no in editor warnings, rollbacks, or anything.
My team also reported another bug in the latest editor, I really wish Unity had proper regressions so it doesn’t fall on us to have to test every release for basic functionality.
Hi and thanks for reporting the issues about WASD keys not working for your setup.
This behavior is related to the keyboard shortcut fix in v1.4.1.
From the CHANGELOG.md:
"Added support for keyboard shortcuts and mutually exclusive use of modifiers.
In short, this means that a “Shift+B” binding can now prevent a “B” binding from triggering.
OneModifierComposite, TwoModifiersComposite, as well as the legacy ButtonWithOneModifierComposite and ButtonWithTwoModifiersComposite now require their modifiers to be pressed before (or at least simultaneously with) pressing the target button.
This check is performed only if the target is a button. For a binding such as “CTRL+MouseDelta” the check is bypassed. It can also be manually bypassed via the overrideModifiersNeedToBePressedFirst.
State change monitors on a device (IInputStateChangeMonitor) are now sorted by their monitorIndex and will trigger in that order.
Actions are now automatically arranging their bindings to trigger in the order of decreasing “complexity”. This metric is derived automatically. The more complex a composite a binding is part of, the higher its complexity. So, “Shift+B” has a higher “complexity” than just “B”.
If an binding of higher complexity “consumes” a given input, all bindings waiting to consume the same input will automatically get skipped. So, if a “Shift+B” binding composite consumes a “B” key press, a binding to “B” that is waiting in line will get skipped and not see the key press.
If your project is broken by these changes, you can disable the new behaviors via a feature toggle in code:
InputSystem.settings.SetInternalFeatureFlag(“DISABLE_SHORTCUT_SUPPORT”, true);"
Due to the above change, having multiple actions bound to the same controls active at the same time could now come into conflict, with one of them “consuming” the input.
In this case there might be other Input Actions enabled within the Input Action Asset also using the WASD keys in a composite binding.
For instance if there is a ‘UI’ Action Map and that is also using the WASD keys for the Navigate Action.
A solution for this case could be to disable any Action Maps which contain duplicate controls when not in use or change/delete any Actions with conflicting controls bound to them.
There is also the feature flag to disable the new shortcut behaviour:
InputSystem.settings.SetInternalFeatureFlag("DISABLE_SHORTCUT_SUPPORT", true);
In the meantime the team is looking into different ways that we can improve this behavior, making it more intuitive and configurable while still being able to keep the shortcut key support as that was a heavily requested feature.
We will keep you posted.
Might be worth releasing v1.4.2 with shortcut support turned off by default and rather include this flag to turn it ON until a better solution has been found:
InputSystem.settings.SetInternalFeatureFlag("ENABLE_SHORTCUT_SUPPORT", true);
You are right, disabling my UI bindings which also use those keys seems to fix it. Is this a bug or a feature though? It’s going to be pretty inconvenient to rewrite the whole game to enabled/disable input action groups.
After the update, I noticed that bindings used in 2DVectors no longer work as button actions. (here: While up arrow is used in the 2D Vector “ButtonAction” is no longer fired, “Vector2Action” does).
@SniperED007 Thanks for the suggestion, 1.4.2 is already in flight with some other critical quality improvements, but we will consider this for the following release.
I’d like to try the InputSystem, but it doesn’t work. Version 2022.2.0b4.2768
Following a simple tutorial, after adding Player Input and “Clicking Actions” I get an error from the InputSystem.Editor.
InvalidOperationException: Failed to add object of type InputActionAsset
. Check that the definition is in a file of the same name and that it compiles properly.
UnityEngine.InputSystem.Editor.InputActionImporter.OnImportAsset (UnityEditor.AssetImporters.AssetImportContext ctx) (at Library/PackageCache/com.unity.inputsystem@1.4.2/InputSystem/Editor/AssetImporter/InputActionImporter.cs:95)
UnityEditor.AssetImporters.ScriptedImporter.GenerateAssetData (UnityEditor.AssetImporters.AssetImportContext ctx) (at :0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)
Additionally, all of my devices are “Unsupported” in the Input Debugger.
Same for me after going from 0b3 to 0b5.
Input system broke completely. Even after going back to 1.3.0 via manifest.json as suggested above, the input maps are still broken and it says they don’t compile.
I reverted back to 0b3.
The exact same reported bug happens in our project.
It’s bizarre to say the least and you should get on that, we thought we were going crazy.
Glad we’re not the only ones, for our minds sake, but can’t believe the package is released with this bug…
The bug is still present in 1.4.2
Arrows also are not working either.
It seems to be working if I remove “Player/Move/WASD” action and “UI/Navigate/Keyboard” but it is really HACKY to do such a thing
Hadesfury
Developing Moons of Ardan: https://www.moonsofardan.com/press.html
Moons of Ardan Twitter Account: https://twitter.com/MoonsOfArdan
Moons of Ardan Steam Page: https://store.steampowered.com/app/1694260/Moons_of_Ardan/
Discord Server: https://discord.gg/gTeucz5bMf
I have the same issue, when I use the keyboard for move, character, moves without control until, I change the direction. (when I released the key, not fire the event phase, cancelled) downgrade to 1.3.0 solved the issue but is present on 1.4.2.
As Hakan explained, only enabling the currently used ActionMap works for me:
private void ChangeInputState(string toActivate)
{
foreach (InputActionMap actionMap in playerInput.actions.actionMaps)
{
if (actionMap.name == toActivate) actionMap.Enable();
else actionMap.Disable();
}
playerInput.SwitchCurrentActionMap(toActivate);
}
I have the same issue as @ibernd .
I cannot use any key used for a Composite Vector2 (E.g. WASD) as a Button Binding for any other Action. This is a must for my game.
@unity_hakan Please let me know if you are aware of this issue and working for a fix in 1.4.3
I downgrade to 1.3.0 and now I can use W as a Button Binding as well as a part of a 2D Vector Composite.
I’ve wasted weeks trying to get the Input System to work. It is so unbelievably finnicky and seems to have several documented, easily reproduceable bugs that make it straight up unusable in most use cases. Easily the most frustrating experience I’ve had with Unity. The lack of quality control is shocking and frankly unacceptable.
Having the same issue.
Kind of shocking to see such a drastic change on how input behaviour is handled with little to no warning or documentation. Recently updated to Input System 1.4.2. and the way we have WASD and Arrow Key input also broke when everything was working previously.
A downgrade to 1.3.0 fixed the issue for the time being. Hope this is addressed somehow and the behaviour improved considerably.