Scroll Rect Vertical#
UI / Scroll / Scroll Rect / Scroll Rect Vertical
Description#
Compares the Vertical property of Scroll Rect component to another value
Parameters#
| Name | Description |
|---|---|
| Scroll Rect |
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("Scroll Rect Vertical")]
[Category("UI/Scroll/Scroll Rect/Vertical")]
[Description("Compares the Vertical property of Scroll Rect component to another value")]
[Image(typeof(IconScrollRect), ColorTheme.Type.TextLight)]
[Keywords("UI, User, Interface")]
[Parameter("Scroll Rect")]
[Serializable]
public class GenConditionBool_ScrollRect_CheckVertical : Condition
{
[SerializeField] private GetGameObject m_ScrollRect = new GetGameObject(
new GenTypeGameObject_ScrollRect()
);
protected override string GetTitle(GameObject source)
{
string member = TextUtils.ThemeAsKeyword("Vertical");
return $"{this.m_ScrollRect} {member}";
}
protected override bool Run(Args args)
{
ScrollRect component = this.m_ScrollRect.Get<ScrollRect>(args);
if (component == null) return false;
return component.vertical;
}
}
}