Documentation index for AI agents (llms.txt) A Markdown version of every page is available: request the page's source under /docs/, follow the "alternate" link in this page's head, or start from /llms.txt.
Visual Script logo Manual

Dropdown Caption Text#

UI / Interaction / Dropdown / Dropdown Caption Text

Description#

Compares the Caption Text property of Dropdown component to another value

Parameters#

Name Description
Dropdown
Value

Code#

// <auto-generated>
// This script was automatically generated using the Visual Script Transpiler.
// Do not modify. Changes to this file will be lost when updating the package.
// </auto-generated>

using System;
using UnityEngine;
using VisualScript.Icons;
using UnityEngine.UI;

namespace VisualScript.Runtime
{
    [Title("Dropdown Caption Text")]
    [Category("UI/Interaction/Dropdown/Caption Text")]
    [Description("Compares the Caption Text property of Dropdown component to another value")]
    
    [Image(typeof(IconUIDropdown), ColorTheme.Type.TextLight)]
    [Keywords("UI, User, Interface")]
    
    [Parameter("Dropdown")]
    [Parameter("Value")]
    
    [Serializable]
    public class GenConditionGameObject_Dropdown_CheckCaptionText : Condition
    {
        [SerializeField] private GetGameObject m_Dropdown = new GetGameObject(
            new GenTypeGameObject_Dropdown()
        );
        
        [SerializeField] private GetGameObject m_Value = new GetGameObject();
        
        protected override string GetTitle(GameObject source)
        {
            string member = TextUtils.ThemeAsKeyword("Caption Text");
            return $"{this.m_Dropdown} {member} = {this.m_Value}";
        }
        
        protected override bool Run(Args args)
        {
            Dropdown component = this.m_Dropdown.Get<Dropdown>(args);
            if (component == null) return false;
            
            return component.captionText == this.m_Value.Get<Text>(args);
        }
    }
}

Visual Script logoVisual Script © Catsoft Works 2026. All rights reserved.