Keyboard and all input suddenly stopped working?

Suddenly, none of my scripts are responding to any inputs at all. Not keyboard, not mouse.
I made a slight tweak in one script, but then changed it back. Nothing. And not all of the scripts that stopped working had been changed.

I don’t see anything obviously wrong, across multiple scenes.

I used Debug.Log to make sure the code was executing in Update(). It is, but it’s not getting any detection of input.

I tried restarting Unity. Nothing. I don’t know what happened.

1 Like

You’re certain that the Game window is focused when you’re playing?

Can you paste the code you’re using for input? It doesn’t sound like it’s code-based, but if you’re doing something weird, it’s possible.

Have you tried creating a new project with a new script that just tests input?

Yes, window is focused.

Ok, I just tried one of the scripts in a new project.
It works there.

So, your project got corrupted somehow. Check Edit → Project Settings → Input and make sure it still has all the axes/buttons set up there. If not, then I’m guessing the settings file got corrupted somehow.

Maybe grab your new project’s ProjectSettings/InputManager.asset file and copy it to your existing project folder in the same place? (close Unity while you do that just to be sure it takes)

Well, it suddenly started working again. Dunno why, I didn’t do anything.

This happens to me a fair bit - resizing the window makes it work again

2 Likes

Just wondering if anyone found more info on this? Happens to me every hour but minimizing or resizing usually fixes it.

3 Likes

Happend too me too. everything except mouse left and right click stoped working. Restarted unity and then everything went back to normal.

4 Likes

All of a sudden, keyboard and all input stopped working here too. I can’t fix it!
Restarting doesn’t work. Neither reinstalling Unity worked.

Resizing or restarting did not work, but starting by the unity made shortcut in the desktop worked. Do not open by the scenes shortcut.

Still happens over here, are we all using steamworks/ the steam overlay by any chance?

I am having same problem Suddenly keyboard appears dead. Is this a Unity issue or my project file? Okay so I installed an older version of the engine and opened a new project … Still nothing!

… I opened new scene and tried 3d person controller and it worked fine But vehicle does not … Purchased a new vehicle controller and it also does not work.

Any ideas?

If you hover over unity in the taskbar and wait for the window preview to appear, right click on the window preview and hit maximize. It may take one or two attempts but this generally fixes it, if it’s the same issue.

Didn’t help. Bought the NWH vehicle physics and the demo works fine But not the prefab nor the vehicle in standard assets 2 days ago standard assets vehicle worked just fine

[SOLVED] For me, it was because I had accidentally deleted Event System from Scene and Graphic Raycaster (component) from UI Canvas. By restoring those items keyboard and mouse are functioning again.

2 Likes

This just happen … Funny part is I did almost everything listed here as what may have caused it …
None of the advice helped sorry to say. I just made a new project and copied over my assets folder.
A few script inputs didn’t copy over to the new project. Scripts was there just not loaded in project … Hmm.
But I was able to run 2 Unity editors and copy over what was missing by hand. Now … back to work!

Just happened to me too. Nothing seemed to work to fix it. Had to do “Export Package” in the broken project. Then create a new project and import it. All is working again. :face_with_spiral_eyes:

Oh geez, it happens from time to time. I use Unity 2018.3.13

Same for me, have you got any luck?

Yes. See my post on Nov 20, 2018 :wink: