Articulation Body Sleep#
Physics 3D / Articulation Body / Articulation Body Sleep
Description#
Executes the Sleep method on the Articulation Body component
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("Articulation Body Sleep")]
[Category("Physics 3D/Articulation Body/Sleep")]
[Description("Executes the Sleep method on the Articulation Body component")]
[Image(typeof(IconPhysics), ColorTheme.Type.Lime, typeof(BadgeDot))]
[Keywords("Physics, 3D")]
[Serializable]
public class GenInstructionArticulationBody_Sleep_0 : Instruction
{
[SerializeField] private GetGameObject m_ArticulationBody = new GetGameObject(
new GenTypeGameObject_ArticulationBody()
);
protected override string GetTitle(GameObject source)
{
string method = TextUtils.ThemeAsKeyword("Sleep");
return $"{this.m_ArticulationBody} {method}";
}
protected override Awaitable Run(Args args)
{
ArticulationBody component = this.m_ArticulationBody.Get<ArticulationBody>(args);
if (component == null) return Done;
component.Sleep();
return Done;
}
}
}