Slider Joint 2D Use Limits#
Physics 2D / Joint / Slider Joint 2D / Slider Joint 2D Use Limits
Description#
Compares the Use Limits property of Slider Joint 2D component to another value
Parameters#
| Name | Description |
|---|---|
| Slider Joint 2D |
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;
namespace VisualScript.Runtime
{
[Title("Slider Joint 2D Use Limits")]
[Category("Physics 2D/Joint/Slider Joint 2D/Use Limits")]
[Description("Compares the Use Limits property of Slider Joint 2D component to another value")]
[Image(typeof(IconSliderJoint), ColorTheme.Type.Lime, typeof(Badge2D))]
[Keywords("Physics, 2D")]
[Parameter("Slider Joint 2D")]
[Serializable]
public class GenConditionBool_SliderJoint2D_CheckUseLimits : Condition
{
[SerializeField] private GetGameObject m_SliderJoint2D = new GetGameObject(
new GenTypeGameObject_SliderJoint2D()
);
protected override string GetTitle(GameObject source)
{
string member = TextUtils.ThemeAsKeyword("Use Limits");
return $"{this.m_SliderJoint2D} {member}";
}
protected override bool Run(Args args)
{
SliderJoint2D component = this.m_SliderJoint2D.Get<SliderJoint2D>(args);
if (component == null) return false;
return component.useLimits;
}
}
}