Search Unity

  1. Check out the Unite LA keynote for updates on the Visual Effect Editor, the FPS Sample, ECS, Unity for Film and more! Watch it now!
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Improved Prefab workflow (includes Nested Prefabs!), 2D isometric Tilemap and more! Get the 2018.3 Beta now.
    Dismiss Notice
  4. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  5. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice
  6. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

TextMesh Pro TMP input (works in Editor, not in standalone)

Discussion in 'Unity UI & TextMesh Pro' started by shaderbytes, Sep 10, 2018.

  1. shaderbytes

    shaderbytes

    Joined:
    Nov 11, 2010
    Posts:
    896
    TMP 1.2.4
    unity 2018.2.2f1
    bulid settings x84_64
    .net 4.x
    Windows 10 64 bit

    as the title says , input fields work in the editor but do not work in the build. They do receive focus and highlight the existing text entered via code when the game launches, but you can not type anything into the fields. They also do not loose focus, or at least the dont clear the highlighted selection when you click another input field.

    They work correctly in the editor
     
  2. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    1,795
    See how Example scene 20 included in the TMP Examples & Extras behaves and if you get the same issues. This should be working. Also make sure you have the correct options selected on the Input Field.
     
  3. shaderbytes

    shaderbytes

    Joined:
    Nov 11, 2010
    Posts:
    896
    I cant think what options only pertain to the editor? As mentioned it works properly in the editor, only doesnt work in the actual standalone.

    (EDIT , I dont have the extras downloaded as i didnt think i would need them )
    (EDIT 2 I just tested example 20 and it works in the standalone, i going to compare the assets and see what is going on here )
     
    Last edited: Sep 10, 2018
  4. shaderbytes

    shaderbytes

    Joined:
    Nov 11, 2010
    Posts:
    896
    mmm.. if i put a input field in the first level panel of my UI then it works in the build , so something in the hierarchy to these problematic input fields is causing an issue, and they are quite nested .. let me investigate more
     
  5. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    1,795
    Make sure the structure of the TMP Input Field is maintained.
     
  6. shaderbytes

    shaderbytes

    Joined:
    Nov 11, 2010
    Posts:
    896
    I didnt mess with the component internals ;) So here is my bizarre finding so far .. after much testing I can only assume that the broken fields didnt work because they were duplicated in the editor. When I deleted all the fields and created each field from the gameobject menu then all works , both editor and standalone. This is definitely bizarre , i mean why would the previous ones work at all if some reference was broken..? Yet they worked in the editor and not standalone.

    I could just be grabbing at straws here but I did do lots of testing and could not find anything causing the issue
     
  7. shaderbytes

    shaderbytes

    Joined:
    Nov 11, 2010
    Posts:
    896
    wow i really tried to get to the bottom of this and no luck. all internals of the inputfield are correct , all references in the input inspector are valid. Oh well, at least replacing them works ;) The project is too big for me to upload a bug report. Just keep it in mind if something like this surfaces again. So the only two clues we have are:

    1. works in editor but not in standalone..
    2. In standalone field selection occurs ( highlighting or cursor placement etc ) but no typing produces anything into the field and also a field does not loose the highlight/cursor blink when you click away from it.
     
  8. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    1,795
    Last time I saw something similar was a user mixing old GUI code with all of this where at some place he had GUI.Enabled = false which under some condition was preventing input due to the Unity event system being affected by this. Ultimately, it wasn't TMP related but it was affecting the input field.

    I have also seen third party addons affecting stuff so you could look there as well.