Polygon Collider 2D Get Total Point Count#
Physics 2D / Collider 2D / Polygon Collider 2D / Polygon Collider 2D Get Total Point Count
Can Read
Cannot Write
Description#
Returns the execution of Get Total Point Count method on the Polygon Collider 2D 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
{
[Get]
[Title("Polygon Collider 2D Get Total Point Count")]
[Category("Physics 2D/Collider 2D/Polygon Collider 2D/Get Total Point Count")]
[Description("Returns the execution of Get Total Point Count method on the Polygon Collider 2D component")]
[Image(typeof(IconPentagonOutline), ColorTheme.Type.Lime, typeof(Badge2D))]
[Keywords("Physics, 2D")]
[Serializable]
public class GenTypeInteger_PolygonCollider2D_GetTotalPointCount_0 : TypeNumber
{
[SerializeField] private GetGameObject m_PolygonCollider2D = new GetGameObject(
new GenTypeGameObject_PolygonCollider2D()
);
public override double Get(Args args)
{
PolygonCollider2D component = this.m_PolygonCollider2D.Get<PolygonCollider2D>(args);
if (component == null) return default;
double value = (double) component.GetTotalPointCount();
return value;
}
public override string ToString()
{
return $"{this.m_PolygonCollider2D} Get Total Point Count";
}
protected override SubscriptionMode Subscription => SubscriptionMode.OnChange;
}
}