Forum rules - please read before posting.

Gather text for dropdown "Cycle" element type in menus?

Hi,

Is there a way for AC to gather text on choices in a Cycle element type in menus? I want to localize these strings in the Speech manager like I can with other element types, like Labels. It seems that gather text ignores these strings. See my screenshot below. I have a Unity UI dropdown for quality settings. "High Quality", "Medium Quality", and "Low Quality" is what Gather Text ignores.

Any suggestions on how to do this is appreciated! Thanks.

Comments

  • Not currently, but I agree that there should be.

    I will look into this. Perhaps the expected linked variable should be of type "PopUp", so that the values can match that in the Variables Manager (which do get translated).

  • Thanks, Chris. I'll find a workaround in the meantime.

  • edited January 2021

    What would be a workaround?
    I use this for Difficulty mode, switch between choices Casual or Normal.
    Casual and Normal do not get gathered.
    AC 1.50f

  • As a workaround I think I ended up not using a dropdown and just used an image swap with star symbols (one star for low quality and up to three for high quality) and had standard UI text above that.

    But it sounds like Chris is saying a Popup variable could also be used if linked to the dropdown? Not sure since I never tried it.

  • But it sounds like Chris is saying a Popup variable could also be used if linked to the dropdown?

    Exactly this. Create a new Global Variable of type PopUp with the values Casual and Normal, and then set your Cycle element's "Cycle type" to "Variable" and reference the new PopUp variable. This variable will be translatable.

  • edited January 2021

    Thank you guys.
    But for some reason it won't cycle it, the value doesn't change when switch between difficulty modes.
    I have this:

    I also check with this, is it right?
    Looks about right to me.

        void OnMouseEnter()
        { 
    
            string difficulty = GlobalVariables.GetPopupValue (281);
            Button useButton = GetComponent <Hotspot>().GetFirstUseButton ();
            if (difficulty == "Casual")
            {
                useButton.iconID = 13;
            }
            else
            {
                useButton.iconID = 11;
            }
        }
    
        void OnMouseExit()
        {   
            string difficulty = GlobalVariables.GetPopupValue (281);
            Button useButton = GetComponent <Hotspot>().GetFirstUseButton ();
            if (difficulty == "Casual")
            {
                useButton.iconID = 13;
            }
            else
            {
                useButton.iconID = 11;
            }
        }   
    
  • My mistake. I'm afraid your AC version is so far back, it supports neither Variable translation nor the use of PopUps in Cycle elements.

    If you must remain using v1.50f, you will have to create a separate Cycle element for each language and show/hide them based on the current language.

  • edited January 2021

    Through script?
    Ok thanks Chris.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.