Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Can't seem to update to latest TextMesh Pro

Discussion in 'UGUI & TextMesh Pro' started by gumboots, Jan 9, 2018.

  1. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    Hi there,

    I am attempting to update from an older version of TextMesh Pro (though the DLL version, not the original).

    If I simply try importing the package over the top of the old one, I get a series of errors saying there are ambiguous reference calls. But if I delete the TextMesh Pro folder and reimport, the errors are gone, but all of my text objects lose references to their scripts.

    Have the IDs of the scripts changed again? Or am I doing something incorrectly?

    Thanks!

    Edit: Here is an example of one of the 15 errors (they all seem related to TMPro_ExtensionMethods):

    Code (CSharp):
    1. Assets/TextMesh Pro/Scripts/TMP_Text.cs(4759,113): error CS0121: The call is ambiguous between the following methods or properties: `TMPro.TMPro_ExtensionMethods.Multiply(this UnityEngine.Color32, UnityEngine.Color32)' and `TMPro.TMPro_ExtensionMethods.Multiply(this UnityEngine.Color32, UnityEngine.Color32)'
     
  2. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,596
    As per the Release and Upgrade notes as well as the information contained in the following sticky post at the top of the forum here, before importing the new TMP package, you should remove the previous version by deleting the "TextMesh Pro" folder.

    Provided you are upgrading to and from the same version type, like source code to source code or DLL to DLL, this should work as expected.

    Also make sure that you do end up with the correct version of the product for the version of Unity that you are using as there is still a bug where the Asset Store can end up providing the wrong version of the asset. If that is the case, I provided direct links to download those releases in that sticky thread / post I linked above.

    Script references should all be maintained as the GUIDs and FileIDs for these version is consistent between releases.

    Give this process another try. Again be sure to backup your project first and let me know if you need further assistance.
     
  3. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    Hi Stephan,

    Thanks for the response. (Inevitably) turns out that it's my fault. I could swear I changed over to the compiled DLL version, however I tried the latest from the forum and the update went smoothly.

    The upgrade didn't, however, fix the issue I'm having sadly. Where for some reason VerticalLayoutGroups with TMPros in them have stopped working somewhere along the way. Each TMPro has a ContentSizeFitter on it, and that is doing its job, but they won't stack nicely on top of each other.
     
  4. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,596
    What version of Unity are you now running?

    Can you post an image of the setup you have in terms of components so I can try to reproduce this on my end?

    P.S. If you are using Unity 2017.3, there is a bug with the RectTransform that could be contributing to this.
     
  5. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    Last edited: Jan 10, 2018
  6. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    Ok, more annoying is that I just did a build on OSX and it isn't broken in the build, but is in the editor? I haven't tried a Windows build yet, but it's broken in the Windows editor as well.
     
  7. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,596
    There is an issue in Unity 2017.3 which would affect layout components but you are on 2017.2 and I don't recall any issues there.

    What version of Unity were you using before you upgraded? I know there were some changes that affect layout components but nothing that comes to mind that would explain the behavior being different between platforms.
     
  8. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    No there's no difference between platforms. Windows and OSX builds are fine, but the editor is broken.
     
  9. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,596
    Is the GameView of a different size between the Editor and those builds? This would cause the layout to be different.

    Just to confirm, you are on 2017.2?
     
  10. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    No it's the same size. Changing it doesn't resolutions doesn't fix it either. It seems that all of the child elements have the correct heights, but the parent Vertical Layout Group and Content Size Fitter isn't resizing to account for the children.

    There's a few warning on child Content Size Fitters, but I'm not sure how else to have the TextMeshPros size to their text?

    Yep, I'm on 2017.2.
     
  11. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,596
    The content size fitter needs to be on the parents as far as I know. I believe this was changed at some point in subsequent Unity releases.
     
  12. gumboots

    gumboots

    Joined:
    May 24, 2011
    Posts:
    298
    Good call! I checked the documentation and you're right, just one goes on the parent. Took a little bit of fiddling around, but it's working now. Thanks very much Stephan!
     
    Stephan_B likes this.
  13. bradbecker

    bradbecker

    Joined:
    Dec 26, 2014
    Posts:
    130
    FYI - I just had this problem and it was because I had moved TMP into the Plugins directory earlier. When I deleted that folder to reinstall TMP to clear up some other problems, it added back to the project at the Assets/ root level and it caused all those extensionmethods ambiguity errors. Moving TMP back to the same folder it used to be in fixed them.