Platform Effector 2D Use Side Friction#
Physics 2D / Effectors / Platform Effector 2D / Platform Effector 2D Use Side Friction
Description#
Compares the Use Side Friction property of Platform Effector 2D component to another value
Parameters#
| Name | Description |
|---|---|
| Platform Effector 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("Platform Effector 2D Use Side Friction")]
[Category("Physics 2D/Effectors/Platform Effector 2D/Use Side Friction")]
[Description("Compares the Use Side Friction property of Platform Effector 2D component to another value")]
[Image(typeof(IconPlatformEffector), ColorTheme.Type.Lime, typeof(Badge2D))]
[Keywords("Physics, 2D")]
[Parameter("Platform Effector 2D")]
[Serializable]
public class GenConditionBool_PlatformEffector2D_CheckUseSideFriction : Condition
{
[SerializeField] private GetGameObject m_PlatformEffector2D = new GetGameObject(
new GenTypeGameObject_PlatformEffector2D()
);
protected override string GetTitle(GameObject source)
{
string member = TextUtils.ThemeAsKeyword("Use Side Friction");
return $"{this.m_PlatformEffector2D} {member}";
}
protected override bool Run(Args args)
{
PlatformEffector2D component = this.m_PlatformEffector2D.Get<PlatformEffector2D>(args);
if (component == null) return false;
return component.useSideFriction;
}
}
}