Il semble que les cookies ne soient pas activés dans votre navigateur. Veuillez activer les cookies pour garantir une expérience du site optimale.
Affichage des résultats 1 à 3 sur 3

Discussion: Name of item?

  1. #1
    Date d'inscription
    juin 2011
    Messages
    162

    Name of item?

    If I have an item, its an instrument. And I want its full name. How do I do that, this dont work, its just gives the start 1 or 2 words from the full name (for crafted instruments):

    item:GetItemInfo():GetName()

    same problem with:

    item:GetName()

  2. #2
    Date d'inscription
    mars 2007
    Messages
    1 590
    Citation Envoyé par Splik Voir le message
    If I have an item, its an instrument. And I want its full name. How do I do that, this dont work, its just gives the start 1 or 2 words from the full name (for crafted instruments):

    item:GetItemInfo():GetName()

    same problem with:

    item:GetName()
    There are two types of crafted instruments that I can craft, the regular Minstrel Instrument recipes and Minstrel Legendary Items. Which type are you referring to? Do you have any special (non-Ascii) characters in the item name?

    When I get the name of a "named" crafted musical instrument - that is, a crafted minstrel instrument that was critted and enscribed, I still get just the base item's name, for instance:"Exquisite Walnut Flute" but it is not truncated, it is the full item name, just not the enscribed name. LIs however work a little differently - before being imbued, I get the same results as a regular item (the base item's name) but after being imbued, if I try item:GetName() I get the full enscribed name (still not truncated) but the ItemInfo:GetName() returns the base item's generic name. I don't know why imbuing seems to change the result of item:GetName() but it was still not truncated. Perhaps if it is an imbued LI your item name is just much longer than any of mine - specifically how many characters does it display?

    EDIT:Since in your OP you mention "the start 1 or 2 words" instead of truncation after a specific number of characters, that sounds more like word wrapping - are you sure you aren't just accidentally displaying the name in a field that is too short to display the whole thing and it is automatically word wrapping? To turn off word wrapping you have to call SetMultiline(false) on text and label fields. Did you try outputting the name to the standard chat using Turbine.Shell.WriteLine() to be sure it's not just a display issue?
    Dernière modification par Garan ; 03/07/2020 à 16h35.

  3. #3
    Date d'inscription
    juin 2011
    Messages
    162
    Very helpful, I didn't think of that. Thank you.

 

 

Règles de messages

  • Vous ne pouvez pas créer de nouvelles discussions
  • Vous ne pouvez pas envoyer des réponses
  • Vous ne pouvez pas envoyer des pièces jointes
  • Vous ne pouvez pas modifier vos messages
  •  

La session de ce formulaire a expiré. Vous devez recharger la page.

Recharger