/// <summary> /// Reads mesh header from binary reader and returns it. /// </summary> /// <param name="br"></param> /// <returns></returns> public static MeshHeader ReadFrom(BinaryReader br) { var result = new MeshHeader(); result.MeshSize = br.ReadInt32(); result.BoneName = br.ReadString(32); result.MeshName = br.ReadString(128); result.JointName = br.ReadString(32); result.Index = br.ReadInt32(); result.Unk9 = br.ReadInt32(); return(result); }
/// <summary> /// Reads mesh group from binary reader and returns it. /// </summary> /// <param name="br"></param> /// <returns></returns> public static MeshGroup ReadFrom(BinaryReader br) { var result = new MeshGroup(); result.Name = br.ReadString(32); result.Unk2 = br.ReadString(32); var meshCount = br.ReadInt32(); for (var i = 0; i < meshCount; ++i) { var meshHeader = MeshHeader.ReadFrom(br); result.MeshHeaders.Add(meshHeader); } return(result); }