mirror of
https://github.com/AssetRipper/AssetRipper.git
synced 2025-12-11 20:15:29 +01:00
- fixed IStreamedClip.CurveCount() being incorrect for some Unity versions - fixed GameObject Curves not using the calculated Slopes
15 lines
428 B
C#
15 lines
428 B
C#
using AssetRipper.SourceGenerated.Subclasses.StreamedClip;
|
|
|
|
namespace AssetRipper.SourceGenerated.Extensions
|
|
{
|
|
public static class StreamedClipExtensions
|
|
{
|
|
public static bool IsSet(this IStreamedClip clip) => clip.Data.Count > 0;
|
|
|
|
public static int CurveCount(this IStreamedClip clip)
|
|
{
|
|
return clip.Has_CurveCount_UInt32() ? (int)clip.CurveCount_UInt32 : clip.CurveCount_UInt16 + clip.DiscreteCurveCount;
|
|
}
|
|
}
|
|
}
|