Search Unity

  1. We want you to join us at GDC this year! Take a peek at all of the events we will be hosting during the week of GDC.
    Dismiss Notice
  2. Tell us about your experience here and you’ll get early access to the 2018 Game Studios report + more goodies.
    Dismiss Notice
  3. Unity 2017.3 has arrived! Read about it here.
    Dismiss Notice
  4. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice
  5. We've closed the job boards. If you're looking for work, or looking to hire check out Unity Connect. You can see more information here.
    Dismiss Notice

2017.3.0p2 - Input.GetKey(..) changes values while Key is pressed in Linux builds.

Discussion in 'Linux' started by mosaic_school, Feb 13, 2018.

  1. mosaic_school

    mosaic_school

    Joined:
    Dec 12, 2012
    Posts:
    31
    In the Linux Editor Input.GetKey(..) returns true constantly while the button is pressed but when I build a Linux Player the values changes and often returns false. Essentually any kind of keyboard based movement is broken as a result.

    I added I mini project to reproduce the behavior - as said in the Linux Editor it works fine but not in a Linux player.

    Probably it even affects Linux builds made on Windows but I can't test that unfortunately.

    And I'm sure the problem wasn't there with 2017.2.
     

    Attached Files:

  2. rjakob13

    rjakob13

    Joined:
    Apr 13, 2016
    Posts:
    39
    I tested it both on Linux Mint 18.3 Cinnamon and Windows 7 and couldn't reproduce the problem. The builds were done with 2017.3.0p2 on Linux and executed in 64bit on both platforms.
    Interestingly the editor just crashed and closed (without a bug report popup) the first time I changed the target platform in the build settings. The second time there was no problem.
     
  3. mosaic_school

    mosaic_school

    Joined:
    Dec 12, 2012
    Posts:
    31
    I'm on Ubuntu 17.10 and also tested 64bit builds which has the problem. Also I send a Windows 64bit to a friend and there was no problem. So it's seems Linux specific (for player).

    I looked a bit further into and thought it might have to to with the "Repeat Keys" settings which is turned on by default on Ubuntu 17.10 on Gnome. However disabling it still has the effect.

    What's kinda strange to me is that in the editor in play mode the problem doesn't occur.
     

    Attached Files:

  4. mosaic_school

    mosaic_school

    Joined:
    Dec 12, 2012
    Posts:
    31
    FYI: I tested on my second PC running also Ubuntu 17.10: same problem.
     
  5. mosaic_school

    mosaic_school

    Joined:
    Dec 12, 2012
    Posts:
    31
    Another update: A colleague did a Linux 64bit build on his Windows 10 machine and it has the same issues on my Ubuntu 17.10 machines. So it's not directly related to the Linux Editor but the Linux Player. If anything the Linux Editor has the solution for a fix since it doesn't have the issue in play mode.

    So I submitted an official bug report.
     
  6. Schubkraft

    Schubkraft

    Unity Technologies

    Joined:
    Dec 3, 2012
    Posts:
    748
    We have a fix in testing internally (updating our SDL version) but it will be a bit until we can get it out.
     
    mosaic_school likes this.
  7. mosaic_school

    mosaic_school

    Joined:
    Dec 12, 2012
    Posts:
    31
    Cool, thx for the update! I hope it will be in for the 2018.1 release so that Linux games built using that version won't be broken. =)