Files
plugin-library/Assets/02.InformationSave/RunTime/Extension/TransformInfoExtension.cs
2025-03-26 09:34:52 +08:00

17 lines
480 B
C#

using UnityEngine;
namespace Stary.Evo.InformationSave
{
public static class TransformInfoExtension
{
public static TransformInfo.Information GetTransformInformation(this Transform tf, string desc)
{
return tf.GetComponent<TransformInfo>()._list.Find(n => n.desc == desc);
}
public static void SetTransformInfo(this Transform tf, string desc)
{
tf.GetComponent<TransformInfo>().Set(desc);
}
}
}