Set Wheel Collider Suspension Expansion Limited#
Physics 3D / Collider / Wheel Collider / Set Wheel Collider Suspension Expansion Limited
Description#
Sets the Suspension Expansion Limited property of Wheel Collider component
Parameters#
| Name | Description |
|---|---|
| Wheel Collider | |
| 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;
namespace VisualScript.Runtime
{
[Title("Set Wheel Collider Suspension Expansion Limited")]
[Category("Physics 3D/Collider/Wheel Collider/Suspension Expansion Limited")]
[Description("Sets the Suspension Expansion Limited property of Wheel Collider component")]
[Image(typeof(IconWheel), ColorTheme.Type.Lime)]
[Keywords("Physics, 3D")]
[Parameter("Wheel Collider")]
[Parameter("Value")]
[Serializable]
public class GenInstructionBool_WheelCollider_SetSuspensionExpansionLimited : Instruction
{
[SerializeField] private GetGameObject m_WheelCollider = new GetGameObject(
new GenTypeGameObject_WheelCollider()
);
[SerializeField] private GetBool m_Value = new GetBool();
protected override string GetTitle(GameObject source)
{
string member = TextUtils.ThemeAsKeyword("Suspension Expansion Limited");
return $"{this.m_WheelCollider} {member} = {this.m_Value}";
}
protected override Awaitable Run(Args args)
{
WheelCollider component = this.m_WheelCollider.Get<WheelCollider>(args);
if (component == null) return Done;
component.suspensionExpansionLimited = (bool) this.m_Value.Get(args);
return Done;
}
}
}