Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Controls ignored and/or locked just after entering Play mode in Editor

Discussion in 'Input System' started by angrypenguin, Aug 29, 2020.

  1. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,509
    I've lately been finding quite significant delays before my Game view accepts input after pressing the Play button. The game is visibly running, but specifically keyboard input does nothing. Sometimes for less than a second, sometimes a few seconds, and I can't tell whether or not pressing keys is required to make it responsive again. Basically, my first key press after hitting Play doesn't do anything.

    Sequence of events:
    - Do some work in Editor.
    - Press "Play".
    - Focus Game view by clicking on it. Things are visibly moving, so it is running.
    - Give keyboard input - arrow keys, WASD, or both. Doesn't matter.
    - Nothing happens.
    - Wait a moment.
    - Repeatedly release and re-press keys.
    - After a moment things start to respond.

    After updating Unity versions to 2020.1.2, during one session I was finding that controls would get locked again for 5 to 10 seconds a short while after it'd been playing. So, for instance, if I was moving left I'd be stuck like that for a while. Incredibly frustrating, as I was ironing out character movement logic at the time and had to wait for the controls to become responsive, then lock up, then unlock, then try out what I was testing... then make changes do it all again.

    Sequence of events:
    - Do some work in Editor.
    - Press "Play".
    - Focus Game view by clicking on it. Things are visibly moving, so it is running.
    - Give keyboard input - arrow keys, WASD, or both. Doesn't matter.
    - Nothing happens.
    - Wait a moment.
    - Give keyboard input as above.
    - Now things respond.
    - Do stuff for a few seconds.
    - At some point controls lock. Whatever keys were being pressed stay "pressed" regardless of what I'm doing.
    - Repeatedly press and release keys.
    - After 5 to 10 seconds, things go back to normal.

    I've only had the second scenario in one Editor session, on one computer. I don't seem to get any of the above with gamepad input. That just works immediately and reliably.

    @Rene-Damm, any ideas on this?
     
  2. Kaldrin

    Kaldrin

    Joined:
    Jul 10, 2018
    Posts:
    42
    I'm having the same problem as your first paragraph with Unity 2020.3 currently
     
  3. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,509
    It's intermittent for me. I see the second scenario a lot, but not all the time. It happens on only one of my computer's, though. The other has never had it.

    Is your machine a laptop, by any chance? My machine where this happens is a laptop.
     
  4. ScreamyCat

    ScreamyCat

    Joined:
    Aug 20, 2019
    Posts:
    1
    Having the exact same problem atm, has a solution been found?
     
  5. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,509
    There's another thread on it so.ewhere with a bunch of staff answers. From memory, last I saw it they were still investigating it, months ago.
     
  6. JizzyMcCornflakes

    JizzyMcCornflakes

    Joined:
    Apr 2, 2019
    Posts:
    1
    Have you checked in console whetther of not 'error pause' is on?