Files
RedHotRoast-ios/Assets/Scripts/ToolKit/GeneralKit.cs
T

25 lines
473 B
C#
Raw Normal View History

2026-04-22 09:52:55 +08:00
using UObject = UnityEngine.Object;
namespace RedHotRoast
2026-04-22 09:52:55 +08:00
{
public static class GeneralKit
{
#region Engine
public static T Instantiate<T>(T original) where T : UObject
{
T obj = UObject.Instantiate(original);
return obj;
}
public static void Destroy(UObject obj)
{
if (obj)
{
UObject.Destroy(obj);
}
}
#endregion
}
}