[B3][Display] Scores Table has weird boxes next to box label

Moderator: NADEO

User avatar
fng_thatoneguy
Posts: 722
Joined: 05 Jan 2011, 18:06
Location: That One Place
Contact:

[B3][Display] Scores Table has weird boxes next to box label

Post by fng_thatoneguy »

See screenshot

There are little white boxes (Unicode character?) to the left each of the boxes in the score table (Royal mode)...
They also appear next to the player stats at the bottom of the score table and the Points Limit specified for the server.
Image
User avatar
steeffeen
Translator
Translator
Posts: 2463
Joined: 14 Oct 2012, 16:22
Location: Germany

Re: [B3][Display] Scores Table has weird boxes next to box l

Post by steeffeen »

Yeah, it's not only my script :D
http://dl.dropbox.com/u/58886549/Screen ... Shot18.jpg

these squares are shown when loclized strings are passed to the user interface, but not in every case (dunno when exactly)
    Game Mode and Title Pack Creator, Developer, ShootMania-Player & more

    ManiaControl, FancyManiaLinks
    User avatar
    Darkminus
    Posts: 228
    Joined: 05 Jun 2012, 20:54
    Location: Dans mon monde.
    Contact:

    Re: [B3][Display] Scores Table has weird boxes next to box l

    Post by Darkminus »

    I got this problem while coding my script on Beta 2.
    This is because they use TextLib::Compose to show things on the screen. I dunno the reason.
    I got rid of that by using concatenation (Var1^Var2)
    Maybe is it different in that case...
    Hope I could help you guys!
    Akbalder
    Posts: 1059
    Joined: 15 Jun 2010, 11:00
    Contact:

    Re: [B3][Display] Scores Table has weird boxes next to box l

    Post by Akbalder »

    I have this problem when I use the _("a string") function.
    Should we modify our scripts or will it be fixed soon?
    User avatar
    steeffeen
    Translator
    Translator
    Posts: 2463
    Joined: 14 Oct 2012, 16:22
    Location: Germany

    Re: [B3][Display] Scores Table has weird boxes next to box l

    Post by steeffeen »

    Akbalder wrote:I have this problem when I use the _("a string") function.
    Should we modify our scripts or will it be fixed soon?
    Exactly! _("Hello") is a string that will be translated and it seems the encoding screws things up...
    i started changing my scripts but then i stopped, because nadeo should definitely fix this, otherwise we wouldn't be able to make localized scripts... i'm pretty sure they will do something about it as it's even broken in their own scripts
      Game Mode and Title Pack Creator, Developer, ShootMania-Player & more

      ManiaControl, FancyManiaLinks
      User avatar
      Eole
      Nadeo
      Nadeo
      Posts: 1265
      Joined: 26 Apr 2011, 21:08

      Re: [B3][Display] Scores Table has weird boxes next to box l

      Post by Eole »

      This bug appears when you concatenate multiple strings with translation at the same time. To avoid that you can use the Compose function of the TextLib library.

      Code: Select all

      declare MyTranslatedString = TextLib::Compose("%1 %2", _("First part of my string"), _("Second part of my string"))
      We also added a new textprefix parameters that you can use in your <label />.

      Code: Select all

      <label textprefix="$s$f0f" text="My text" />
      With this you won't have to do things like this anymore to style your text (it breaks the translation mechanism):

      Code: Select all

      declare MyString = "$s$f0f"^_("Translate me: ")^Player.Name;
      declare Manialink = """<label text="{{{MyString}}}" />""";
      Better:

      Code: Select all

      declare MyString = TextLib::Compose(_("Translate me: %1"), Player.Name);
      declare Manialink = """<label textprefix="$s$f0f" text="{{{MyString}}}" />""";
      Contribute to the ManiaPlanet documentation on GitHub
      A question about ManiaScript? Ask it here!
      User avatar
      steeffeen
      Translator
      Translator
      Posts: 2463
      Joined: 14 Oct 2012, 16:22
      Location: Germany

      Re: [B3][Display] Scores Table has weird boxes next to box l

      Post by steeffeen »

      Eole wrote:This bug appears when you concatenate multiple strings with translation at the same time. To avoid that you can use the Compose function of the TextLib library.

      Code: Select all

      declare MyTranslatedString = TextLib::Compose("%1 %2", _("First part of my string"), _("Second part of my string"))
      We also added a new textprefix parameters that you can use in your <label />.

      Code: Select all

      <label textprefix="$s$f0f" text="My text" />
      With this you won't have to do things like this anymore to style your text (it breaks the translation mechanism):

      Code: Select all

      declare MyString = "$s$f0f"^_("Translate me: ")^Player.Name;
      declare Manialink = """<label text="{{{MyString}}}" />""";
      Better:

      Code: Select all

      declare MyString = TextLib::Compose(_("Translate me: %1"), Player.Name);
      declare Manialink = """<label textprefix="$s$f0f" text="{{{MyString}}}" />""";
      Thanks for sharing the knowledge! :thumbsup: :thx:
      I hope the nadeo script will be updated soon? :D
        Game Mode and Title Pack Creator, Developer, ShootMania-Player & more

        ManiaControl, FancyManiaLinks
        User avatar
        Eole
        Nadeo
        Nadeo
        Posts: 1265
        Joined: 26 Apr 2011, 21:08

        Re: [B3][Display] Scores Table has weird boxes next to box l

        Post by Eole »

        They have been updated for the release. But we probably missed some translations. If you can report in which mode you saw it, it will help us to correct it faster. ;)
        Contribute to the ManiaPlanet documentation on GitHub
        A question about ManiaScript? Ask it here!
        User avatar
        fng_thatoneguy
        Posts: 722
        Joined: 05 Jan 2011, 18:06
        Location: That One Place
        Contact:

        Re: [B3][Display] Scores Table has weird boxes next to box l

        Post by fng_thatoneguy »

        fng_thatoneguy wrote:See screenshot

        There are little white boxes (Unicode character?) to the left each of the boxes in the score table (Royal mode)...
        They also appear next to the player stats at the bottom of the score table and the Points Limit specified for the server.
        Royal mode
        Image
        User avatar
        Emilieng
        Posts: 70
        Joined: 17 Dec 2012, 13:13
        Contact:

        Re: [B3][Display] Scores Table has weird boxes next to box l

        Post by Emilieng »

        Thanks for the screenshot.
        It seems to be taken from an old version of Royal script.
        This will be corrected as soon as this server is up to date.
        Locked

        Return to “Shootmania Storm Reports”

        Who is online

        Users browsing this forum: No registered users and 1 guest