Add support for latest Tuanjie versions (up to v1.9)

still partial
This commit is contained in:
VaDiM
2026-05-27 02:50:58 +03:00
parent 22e4b0e8a1
commit 7adfdef62f
12 changed files with 392 additions and 181 deletions
+6 -40
View File
@@ -1,4 +1,5 @@
using System;
using AssetStudio.Classes.Tuanjie.AnimationClip;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
@@ -682,45 +683,6 @@ namespace AssetStudio
}
}
public class ACLClip //Tuanjie
{
public uint m_FrameCount;
public uint m_BoneCount;
public float m_SampleRate;
public uint m_CurveCount;
public byte[] m_Tracks;
public uint[] m_ACLDecoderMap;
public bool m_UseACLFastSampleMode;
public ACLClip() { }
public ACLClip(ObjectReader reader)
{
var version = reader.version;
m_FrameCount = reader.ReadUInt32();
m_BoneCount = reader.ReadUInt32();
m_SampleRate = reader.ReadSingle();
if (version >= (2022, 3, 55)) //2022.3.55t1(1.5.0) and up
{
m_CurveCount = reader.ReadUInt32();
}
m_Tracks = reader.ReadUInt8Array();
if (version >= (2022, 3, 61)) //2022.3.61t1(1.6.0) and up
{
reader.AlignStream();
}
m_ACLDecoderMap = reader.ReadUInt32Array();
if (version > (2022, 3, 55) || (version == (2022, 3, 55) && version.Build >= 4)) //2022.3.55t4(1.5.3) and up
{
m_UseACLFastSampleMode = reader.ReadBoolean();
if (version >= (2022, 3, 61)) //2022.3.61t1(1.6.0) and up
{
reader.AlignStream();
}
}
}
}
public class OffsetPtr
{
public Clip data;
@@ -899,6 +861,10 @@ namespace AssetStudio
}
m_Mirror = reader.ReadBoolean();
if (version.IsTuanjie && version >= (2022, 3, 62, 8)) //2022.3.62t8(1.9.0) and up
{
var m_LockToRoot = reader.ReadBoolean();
}
if (version >= (4, 3)) //4.3 and up
{
m_LoopTime = reader.ReadBoolean();