Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Enter the 2020.2 Beta Sweepstakes for a chance to win an Oculus Quest 2.
    Dismiss Notice

Feedback [2018.1.6f1] UI double character input, no resolution dialogue & black full screen

Discussion in 'Linux Editor' started by Reizla, May 11, 2019.

  1. Reizla

    Reizla

    Joined:
    Nov 5, 2013
    Posts:
    136
    I'm still using 2018.1.6.f1 because I'm still using the deprecated RPC calls for a MMO I'm writing. I'm sure the newer (and pretty undocumented) lower network can handle this task, for me and/or how to implement it seems pretty foggy (again, it's pretty undocumented).

    That being said, I've stumbled on 3 problems with my compiled code:
    1. In the attached screenshot I'm showing both the Unity editor and the executable running the same code. In both UIs I've pressed the 'a' key only once. In the editor I get a single 'a' as it should be, but in the executable it shows 'aa'. I can work around this problem with the compiler directive #IF LINUX (need to check the actual directive), catch the key pressed and edit the output (string) to show only a single char. IMO this should not happen on the executable side though.
    2. I've set the player in the editor to show the resolution dialogue, but it's not popping up and it immediately starts with the game in the set player resolution (720p in this case).
    3. When I'm running the executable in full screen, it turns my monitors completely black and I can't end/close it. I think this might have something to do with my kinda 'odd' monitor setup. I use 3 1080p monitors, of which the left one is in portrait (more code to see ;-). Oddly enough when I used this under Windows (non-VM) with the same monitor setup it'd default to the OS's default monitor (middle, being landscape - same as configured under Ubuntu). I'm not sure is there's some work around for this (my specific?) problem.

    Anyone having similar problems and /or have solutions?
    @Devs. should I file a bug report for these problems with this older version?


    [EDIT]
    Here's the code I'm using, including the added compiler directives:

    Code (CSharp):
    1.     public void InputeMailAddressCheck() {
    2.         string ValidChars="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890._@";
    3.  
    4.         if(InputeMailAddress.text.Length > 0) {
    5.             if(ValidChars.IndexOf(InputeMailAddress.text[InputeMailAddress.text.Length - 1]) > -1) {
    6.  
    7. #if UNITY_STANDALONE_LINUX && !UNITY_EDITOR_LINUX
    8.                 InputeMailAddress.text = InputeMailAddress.text.Remove(InputeMailAddress.text.Length - 1);
    9. #endif
    10.  
    11.                 if(!(InputeMailAddress.text.Contains("@") && InputeMailAddress.text.Contains("."))) {  // Check validity of email address
    12.                     TextItemMessage.text = "Please enter a valid eMail address "+InputeMailAddress.text;
    13.                     ImageWarningeMailAddress.transform.localPosition = new Vector3(ImageWarningeMailAddress.transform.localPosition.x,ImageWarningeMailAddress.transform.localPosition.y,0);
    14.                 }
    15.                 else {
    16.                     TextItemMessage.text = "";
    17.                     ImageWarningeMailAddress.transform.localPosition = new Vector3(ImageWarningeMailAddress.transform.localPosition.x,ImageWarningeMailAddress.transform.localPosition.y,-2);
    18.                 }
    19.             }
    20.             else InputeMailAddress.text = InputeMailAddress.text.Remove(InputeMailAddress.text.Length - 1);
    21.         }
    22.     }
    Weird thing is that the compiler directive #if UNITY_STANDALONE_LINUX (or #if PLATFORM_STANDALONE_LINUX I used in an other similar method) should fix it, yet these directives cancel out all input. Oddly enough I need to add the && !UNITY_EDITOR_LINUX to the directive or it'll without it the input is canceled out using the editor.

    Needless to say that I'm at a complete loss here.
     

    Attached Files:

    Last edited: May 11, 2019
unityunity