Exemplo n.º 1
0
        /// <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_10h       = reader.ReadUInt32();
            this.Unknown_14h       = reader.ReadUInt32();
            this.Unknown_18h       = reader.ReadUInt32();
            this.Unknown_1Ch       = reader.ReadUInt32();
            this.ClassInfosPointer = reader.ReadUInt64();
            this.p2 = reader.ReadUInt64();
            this.DataBlocksPointer = reader.ReadUInt64();
            this.NamePointer       = reader.ReadUInt64();
            this.p5 = reader.ReadUInt64();
            this.ClassInfosCount = reader.ReadUInt16();
            this.c2 = reader.ReadUInt16();
            this.DataBlocksCount = reader.ReadUInt16();
            this.Unknown_4Eh     = reader.ReadUInt16();
            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();

            // read reference data
            this.ClassInfos = reader.ReadBlockAt <ResourceSimpleArray <MetaClassInfo_GTA5_pc> >(
                this.ClassInfosPointer, // offset
                this.ClassInfosCount
                );
            this.p2data = reader.ReadBlockAt <ResourceSimpleArray <Unknown_META_002> >(
                this.p2, // offset
                this.c2
                );
            this.DataBlocks = reader.ReadBlockAt <ResourceSimpleArray <MetaDataBlock_GTA5_pc> >(
                this.DataBlocksPointer, // offset
                this.DataBlocksCount
                );
            this.Name = reader.ReadBlockAt <string_r>(
                this.NamePointer // offset
                );
            this.p5data = reader.ReadBlockAt <Unknown_META_001>(
                this.p5 // offset
                );
        }
Exemplo n.º 2
0
        /// <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_10h = reader.ReadUInt32();
            this.Unknown_14h = reader.ReadUInt32();
            this.Unknown_18h = reader.ReadUInt32();
            this.Unknown_1Ch = reader.ReadUInt32();
            this.ClassInfosPointer = reader.ReadUInt64();
            this.p2 = reader.ReadUInt64();
            this.DataBlocksPointer = reader.ReadUInt64();
            this.NamePointer = reader.ReadUInt64();
            this.p5 = reader.ReadUInt64();
            this.ClassInfosCount = reader.ReadUInt16();
            this.c2 = reader.ReadUInt16();
            this.DataBlocksCount = reader.ReadUInt16();
            this.Unknown_4Eh = reader.ReadUInt16();
            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();

            // read reference data
            this.ClassInfos = reader.ReadBlockAt<ResourceSimpleArray<MetaClassInfo_GTA5_pc>>(
                this.ClassInfosPointer, // offset
                this.ClassInfosCount
            );
            this.p2data = reader.ReadBlockAt<ResourceSimpleArray<Unknown_META_002>>(
                this.p2, // offset
                this.c2
            );
            this.DataBlocks = reader.ReadBlockAt<ResourceSimpleArray<MetaDataBlock_GTA5_pc>>(
                this.DataBlocksPointer, // offset
                this.DataBlocksCount
            );
            this.Name = reader.ReadBlockAt<string_r>(
                this.NamePointer // offset
            );
            this.p5data = reader.ReadBlockAt<Unknown_META_001>(
                this.p5 // offset
            );
        }