/// <summary> /// Reads the data-block from a stream. /// </summary> public override void Read(ResourceDataReader reader, params object[] parameters) { // read structure data this.VFT = reader.ReadUInt32(); this.Unknown_4h = reader.ReadUInt32(); this.Unknown_8h = reader.ReadUInt32(); this.Unknown_Ch = reader.ReadUInt32(); this.Unknown_10h = reader.ReadUInt32(); this.Unknown_14h = reader.ReadUInt32(); this.VertexBufferPointer = reader.ReadUInt64(); this.Unknown_20h = reader.ReadUInt32(); this.Unknown_24h = reader.ReadUInt32(); this.Unknown_28h = reader.ReadUInt32(); this.Unknown_2Ch = reader.ReadUInt32(); this.Unknown_30h = reader.ReadUInt32(); this.Unknown_34h = reader.ReadUInt32(); this.IndexBufferPointer = reader.ReadUInt64(); this.Unknown_40h = reader.ReadUInt32(); this.Unknown_44h = reader.ReadUInt32(); this.Unknown_48h = reader.ReadUInt32(); this.Unknown_4Ch = reader.ReadUInt32(); this.Unknown_50h = reader.ReadUInt32(); this.Unknown_54h = reader.ReadUInt32(); this.IndicesCount = reader.ReadUInt32(); this.TrianglesCount = reader.ReadUInt32(); this.VerticesCount = reader.ReadUInt16(); this.Unknown_62h = reader.ReadUInt16(); this.Unknown_64h = reader.ReadUInt32(); this.BoneIdsPointer = reader.ReadUInt64(); this.VertexStride = reader.ReadUInt16(); this.BoneIdsCount = reader.ReadUInt16(); this.Unknown_74h = reader.ReadUInt32(); this.VertexDataPointer = reader.ReadUInt64(); this.Unknown_80h = reader.ReadUInt32(); this.Unknown_84h = reader.ReadUInt32(); this.Unknown_88h = reader.ReadUInt32(); this.Unknown_8Ch = reader.ReadUInt32(); this.Unknown_90h = reader.ReadUInt32(); this.Unknown_94h = reader.ReadUInt32(); // read reference data this.VertexBuffer = reader.ReadBlockAt <VertexBuffer>( this.VertexBufferPointer // offset ); this.IndexBuffer = reader.ReadBlockAt <IndexBuffer>( this.IndexBufferPointer // offset ); this.BoneIds = reader.ReadBlockAt <ResourceSimpleArray <ushort_r> >( this.BoneIdsPointer, // offset this.BoneIdsCount ); this.VertexData = reader.ReadBlockAt <VertexData_GTA5_pc>( this.VertexDataPointer, // offset this.VertexStride, this.VerticesCount, this.VertexBuffer.Info ); }
/// <summary> /// Reads the data-block from a stream. /// </summary> public override void Read(ResourceDataReader reader, params object[] parameters) { // read structure data this.VFT = reader.ReadUInt32(); this.Unknown_4h = reader.ReadUInt32(); this.VertexStride = reader.ReadUInt16(); this.Unknown_Ah = reader.ReadUInt16(); this.Unknown_Ch = reader.ReadUInt32(); this.DataPointer1 = reader.ReadUInt64(); this.VertexCount = reader.ReadUInt32(); this.Unknown_1Ch = reader.ReadUInt32(); this.DataPointer2 = reader.ReadUInt64(); this.Unknown_28h = reader.ReadUInt32(); this.Unknown_2Ch = reader.ReadUInt32(); this.InfoPointer = reader.ReadUInt64(); this.Unknown_38h = reader.ReadUInt32(); this.Unknown_3Ch = reader.ReadUInt32(); this.Unknown_40h = reader.ReadUInt32(); this.Unknown_44h = reader.ReadUInt32(); this.Unknown_48h = reader.ReadUInt32(); this.Unknown_4Ch = reader.ReadUInt32(); this.Unknown_50h = reader.ReadUInt32(); this.Unknown_54h = reader.ReadUInt32(); this.Unknown_58h = reader.ReadUInt32(); this.Unknown_5Ch = reader.ReadUInt32(); this.Unknown_60h = reader.ReadUInt32(); this.Unknown_64h = reader.ReadUInt32(); this.Unknown_68h = reader.ReadUInt32(); this.Unknown_6Ch = reader.ReadUInt32(); this.Unknown_70h = reader.ReadUInt32(); this.Unknown_74h = reader.ReadUInt32(); this.Unknown_78h = reader.ReadUInt32(); this.Unknown_7Ch = reader.ReadUInt32(); // read reference data this.Info = reader.ReadBlockAt <VertexDeclaration>( this.InfoPointer // offset ); this.Data1 = reader.ReadBlockAt <VertexData_GTA5_pc>( this.DataPointer1, // offset this.VertexStride, this.VertexCount, this.Info ); this.Data2 = reader.ReadBlockAt <VertexData_GTA5_pc>( this.DataPointer2, // offset this.VertexStride, this.VertexCount, this.Info ); if (this.Data1 == null && this.Data2 != null) { this.Data1 = this.Data2; } }
/// <summary> /// Reads the data-block from a stream. /// </summary> public override void Read(ResourceDataReader reader, params object[] parameters) { base.Read(reader, parameters); // read structure data this.Unknown_8h = reader.ReadUInt64(); this.Unknown_10h = reader.ReadUInt64(); this.VertexBufferPointer = reader.ReadUInt64(); this.Unknown_20h = reader.ReadUInt64(); this.Unknown_28h = reader.ReadUInt64(); this.Unknown_30h = reader.ReadUInt64(); this.IndexBufferPointer = reader.ReadUInt64(); this.Unknown_40h = reader.ReadUInt64(); this.Unknown_48h = reader.ReadUInt64(); this.Unknown_50h = reader.ReadUInt64(); this.IndicesCount = reader.ReadUInt32(); this.FacesCount = reader.ReadUInt32(); this.VerticesCount = reader.ReadUInt16(); this.IndicesPerFace = reader.ReadUInt16(); this.Unknown_64h = reader.ReadUInt32(); this.BonesIdPointer = reader.ReadUInt64(); this.VertexStride = reader.ReadUInt16(); this.BonesCount = reader.ReadUInt16(); this.Unknown_74h = reader.ReadUInt32(); this.VertexDataPointer = reader.ReadUInt64(); this.Unknown_80h = reader.ReadUInt64(); this.Unknown_88h = reader.ReadUInt64(); this.Unknown_90h = reader.ReadUInt64(); this.Unknown_98h = reader.ReadUInt64(); // read reference data this.VertexBuffer = reader.ReadBlockAt <VertexBuffer>( this.VertexBufferPointer // offset ); this.IndexBuffer = reader.ReadBlockAt <IndexBuffer>( this.IndexBufferPointer // offset ); this.BonesId = reader.ReadBlockAt <SimpleArray <ushort> >( this.BonesIdPointer, // offset this.BonesCount ); this.VertexData = reader.ReadBlockAt <VertexData_GTA5_pc>( this.VertexDataPointer, // offset this.VertexStride, this.VerticesCount, this.VertexBuffer.Info ); }
/// <summary> /// Reads the data-block from a stream. /// </summary> public override void Read(ResourceDataReader reader, params object[] parameters) { // read structure data this.VFT = reader.ReadUInt32(); this.Unknown_4h = reader.ReadUInt32(); this.Unknown_8h = reader.ReadUInt32(); this.Unknown_Ch = reader.ReadUInt32(); this.Unknown_10h = reader.ReadUInt32(); this.Unknown_14h = reader.ReadUInt32(); this.VertexBufferPointer = reader.ReadUInt64(); this.Unknown_20h = reader.ReadUInt32(); this.Unknown_24h = reader.ReadUInt32(); this.Unknown_28h = reader.ReadUInt32(); this.Unknown_2Ch = reader.ReadUInt32(); this.Unknown_30h = reader.ReadUInt32(); this.Unknown_34h = reader.ReadUInt32(); this.IndexBufferPointer = reader.ReadUInt64(); this.Unknown_40h = reader.ReadUInt32(); this.Unknown_44h = reader.ReadUInt32(); this.Unknown_48h = reader.ReadUInt32(); this.Unknown_4Ch = reader.ReadUInt32(); this.Unknown_50h = reader.ReadUInt32(); this.Unknown_54h = reader.ReadUInt32(); this.IndicesCount = reader.ReadUInt32(); this.Unknown_5Ch = reader.ReadUInt32(); this.VerticesCount = reader.ReadUInt16(); this.Unknown_62h = reader.ReadUInt16(); this.Unknown_64h = reader.ReadUInt32(); this.Unknown_68h_Pointer = reader.ReadUInt64(); this.VertexStride = reader.ReadUInt16(); this.Count1 = reader.ReadUInt16(); this.Unknown_74h = reader.ReadUInt32(); this.VertexDataPointer = reader.ReadUInt64(); this.Unknown_80h = reader.ReadUInt32(); this.Unknown_84h = reader.ReadUInt32(); this.Unknown_88h = reader.ReadUInt32(); this.Unknown_8Ch = reader.ReadUInt32(); this.Unknown_90h = reader.ReadUInt32(); this.Unknown_94h = reader.ReadUInt32(); // read reference data this.VertexBuffer = reader.ReadBlockAt<VertexBuffer_GTA5_pc>( this.VertexBufferPointer // offset ); this.IndexBuffer = reader.ReadBlockAt<IndexBuffer_GTA5_pc>( this.IndexBufferPointer // offset ); this.Unknown_68h_Data = reader.ReadBlockAt<ResourceSimpleArray<ushort_r>>( this.Unknown_68h_Pointer, // offset this.Count1 ); this.VertexData = reader.ReadBlockAt<VertexData_GTA5_pc>( this.VertexDataPointer, // offset this.VertexStride, this.VerticesCount ); }
/// <summary> /// Reads the data-block from a stream. /// </summary> public override void Read(ResourceDataReader reader, params object[] parameters) { // read structure data this.VFT = reader.ReadUInt32(); this.Unknown_4h = reader.ReadUInt32(); this.VertexStride = reader.ReadUInt16(); this.Unknown_Ah = reader.ReadUInt16(); this.Unknown_Ch = reader.ReadUInt32(); this.DataPointer1 = reader.ReadUInt64(); this.VertexCount = reader.ReadUInt32(); this.Unknown_1Ch = reader.ReadUInt32(); this.DataPointer2 = reader.ReadUInt64(); this.Unknown_28h = reader.ReadUInt32(); this.Unknown_2Ch = reader.ReadUInt32(); this.InfoPointer = reader.ReadUInt64(); this.Unknown_38h = reader.ReadUInt32(); this.Unknown_3Ch = reader.ReadUInt32(); this.Unknown_40h = reader.ReadUInt32(); this.Unknown_44h = reader.ReadUInt32(); this.Unknown_48h = reader.ReadUInt32(); this.Unknown_4Ch = reader.ReadUInt32(); this.Unknown_50h = reader.ReadUInt32(); this.Unknown_54h = reader.ReadUInt32(); this.Unknown_58h = reader.ReadUInt32(); this.Unknown_5Ch = reader.ReadUInt32(); this.Unknown_60h = reader.ReadUInt32(); this.Unknown_64h = reader.ReadUInt32(); this.Unknown_68h = reader.ReadUInt32(); this.Unknown_6Ch = reader.ReadUInt32(); this.Unknown_70h = reader.ReadUInt32(); this.Unknown_74h = reader.ReadUInt32(); this.Unknown_78h = reader.ReadUInt32(); this.Unknown_7Ch = reader.ReadUInt32(); // read reference data this.Info = reader.ReadBlockAt<VertexDeclaration_GTA5_pc>( this.InfoPointer // offset ); this.Data1 = reader.ReadBlockAt<VertexData_GTA5_pc>( this.DataPointer1, // offset this.VertexStride, this.VertexCount, this.Info ); this.Data2 = reader.ReadBlockAt<VertexData_GTA5_pc>( this.DataPointer2, // offset this.VertexStride, this.VertexCount, this.Info ); }