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.Unknown_20h = reader.ReadUInt32();
			this.Unknown_24h = reader.ReadUInt32();
			this.Unknown_28h = reader.ReadUInt32();
			this.Unknown_2Ch = reader.ReadUInt32();
			this.DrawablePointer = reader.ReadUInt64();
			this.Unknown_28h_Pointer = reader.ReadUInt64();
			this.Unknown_30h_Pointer = reader.ReadUInt64();
			this.Count0 = reader.ReadUInt32();
			this.Unknown_4Ch = reader.ReadUInt32();
			this.Unknown_50h = reader.ReadUInt32();
			this.Unknown_54h = reader.ReadUInt32();
			this.NamePointer = reader.ReadUInt64();
			this.Unknown_60h_Pointer = reader.ReadUInt64();
			this.Count1 = reader.ReadUInt16();
			this.Count2 = reader.ReadUInt16();
			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();
			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();
			this.Unknown_98h = reader.ReadUInt32();
			this.Unknown_9Ch = reader.ReadUInt32();
			this.Unknown_A0h = reader.ReadUInt32();
			this.Unknown_A4h = reader.ReadUInt32();
			this.Unknown_A8h_Pointer = reader.ReadUInt64();
			this.Unknown_B0h = reader.ReadUInt32();
			this.Unknown_B4h = reader.ReadUInt32();
			this.Unknown_B8h = reader.ReadUInt32();
			this.Unknown_BCh = reader.ReadUInt32();
			this.Unknown_C0h = reader.ReadUInt32();
			this.Unknown_C4h = reader.ReadUInt32();
			this.Unknown_C8h = reader.ReadUInt32();
			this.Unknown_CCh = reader.ReadUInt32();
			this.Unknown_D0h = reader.ReadUInt32();
			this.Unknown_D4h = reader.ReadUInt32();
			this.Unknown_D8h = reader.ReadByte();
			this.Count3 = reader.ReadByte();
			this.Unknown_DAh = reader.ReadUInt16();
			this.Unknown_DCh = reader.ReadUInt32();
			this.Unknown_E0h_Pointer = reader.ReadUInt64();
			this.Unknown_E8h = reader.ReadUInt32();
			this.Unknown_ECh = reader.ReadUInt32();
			this.PhysicsLODGroupPointer = reader.ReadUInt64();
			this.Unknown_F8h_Pointer = reader.ReadUInt64();
			this.Unknown_100h = reader.ReadUInt32();
			this.Unknown_104h = reader.ReadUInt32();
			this.Unknown_108h = reader.ReadUInt32();
			this.Unknown_10Ch = reader.ReadUInt32();
			this.LightAttributesPointer = reader.ReadUInt64();
			this.LightAttributesCount = reader.ReadUInt16();
			this.Count5 = reader.ReadUInt16();
			this.Unknown_11Ch = reader.ReadUInt32();
			this.Unknown_120h_Pointer = reader.ReadUInt64();
			this.Unknown_128h = reader.ReadUInt32();
			this.Unknown_12Ch = reader.ReadUInt32();

			// read reference data
			this.Drawable = reader.ReadBlockAt<FragDrawable_GTA5_pc>(
				this.DrawablePointer // offset
			);
			this.Unknown_28h_Data = reader.ReadBlockAt<ResourcePointerArray64<FragDrawable_GTA5_pc>>(
				this.Unknown_28h_Pointer, // offset
				this.Count0
			);
			this.Unknown_30h_Data = reader.ReadBlockAt<ResourcePointerArray64<string_r>>(
				this.Unknown_30h_Pointer, // offset
				this.Count0
			);
			this.Name = reader.ReadBlockAt<string_r>(
				this.NamePointer // offset
			);
			this.Unknown_60h_Data = reader.ReadBlockAt<ResourcePointerArray64<Unknown_F_011>>(
				this.Unknown_60h_Pointer, // offset
				this.Count1
			);
			this.Unknown_A8h_Data = reader.ReadBlockAt<Unknown_F_004>(
				this.Unknown_A8h_Pointer // offset
			);
			this.Unknown_E0h_Data = reader.ReadBlockAt<ResourcePointerArray64<Unknown_F_006>>(
				this.Unknown_E0h_Pointer, // offset
				this.Count3
			);
			this.PhysicsLODGroup = reader.ReadBlockAt<FragPhysicsLODGroup_GTA5_pc>(
				this.PhysicsLODGroupPointer // offset
			);
			this.Unknown_F8h_Data = reader.ReadBlockAt<FragDrawable_GTA5_pc>(
				this.Unknown_F8h_Pointer // offset
			);
			this.LightAttributes = reader.ReadBlockAt<ResourceSimpleArray<LightAttributes_GTA5_pc>>(
				this.LightAttributesPointer, // offset
				this.LightAttributesCount
			);
			this.Unknown_120h_Data = reader.ReadBlockAt<Unknown_F_003>(
				this.Unknown_120h_Pointer // 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.Unknown_20h         = reader.ReadUInt32();
            this.Unknown_24h         = reader.ReadUInt32();
            this.Unknown_28h         = reader.ReadUInt32();
            this.Unknown_2Ch         = reader.ReadUInt32();
            this.DrawablePointer     = reader.ReadUInt64();
            this.Unknown_28h_Pointer = reader.ReadUInt64();
            this.Unknown_30h_Pointer = reader.ReadUInt64();
            this.Count0                 = reader.ReadUInt32();
            this.Unknown_4Ch            = reader.ReadUInt32();
            this.Unknown_50h            = reader.ReadUInt32();
            this.Unknown_54h            = reader.ReadUInt32();
            this.NamePointer            = reader.ReadUInt64();
            this.Unknown_60h_Pointer    = reader.ReadUInt64();
            this.Count1                 = reader.ReadUInt16();
            this.Count2                 = reader.ReadUInt16();
            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();
            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();
            this.Unknown_98h            = reader.ReadUInt32();
            this.Unknown_9Ch            = reader.ReadUInt32();
            this.Unknown_A0h            = reader.ReadUInt32();
            this.Unknown_A4h            = reader.ReadUInt32();
            this.Unknown_A8h_Pointer    = reader.ReadUInt64();
            this.Unknown_B0h            = reader.ReadUInt32();
            this.Unknown_B4h            = reader.ReadUInt32();
            this.Unknown_B8h            = reader.ReadUInt32();
            this.Unknown_BCh            = reader.ReadUInt32();
            this.Unknown_C0h            = reader.ReadUInt32();
            this.Unknown_C4h            = reader.ReadUInt32();
            this.Unknown_C8h            = reader.ReadUInt32();
            this.Unknown_CCh            = reader.ReadUInt32();
            this.Unknown_D0h            = reader.ReadUInt32();
            this.Unknown_D4h            = reader.ReadUInt32();
            this.Unknown_D8h            = reader.ReadByte();
            this.Count3                 = reader.ReadByte();
            this.Unknown_DAh            = reader.ReadUInt16();
            this.Unknown_DCh            = reader.ReadUInt32();
            this.Unknown_E0h_Pointer    = reader.ReadUInt64();
            this.Unknown_E8h            = reader.ReadUInt32();
            this.Unknown_ECh            = reader.ReadUInt32();
            this.PhysicsLODGroupPointer = reader.ReadUInt64();
            this.Unknown_F8h_Pointer    = reader.ReadUInt64();
            this.Unknown_100h           = reader.ReadUInt32();
            this.Unknown_104h           = reader.ReadUInt32();
            this.Unknown_108h           = reader.ReadUInt32();
            this.Unknown_10Ch           = reader.ReadUInt32();
            this.LightAttributesPointer = reader.ReadUInt64();
            this.LightAttributesCount   = reader.ReadUInt16();
            this.Count5                 = reader.ReadUInt16();
            this.Unknown_11Ch           = reader.ReadUInt32();
            this.Unknown_120h_Pointer   = reader.ReadUInt64();
            this.Unknown_128h           = reader.ReadUInt32();
            this.Unknown_12Ch           = reader.ReadUInt32();

            // read reference data
            this.Drawable = reader.ReadBlockAt <FragDrawable_GTA5_pc>(
                this.DrawablePointer                 // offset
                );
            this.Unknown_28h_Data = reader.ReadBlockAt <ResourcePointerArray64 <FragDrawable_GTA5_pc> >(
                this.Unknown_28h_Pointer,                 // offset
                this.Count0
                );
            this.Unknown_30h_Data = reader.ReadBlockAt <ResourcePointerArray64 <string_r> >(
                this.Unknown_30h_Pointer,                 // offset
                this.Count0
                );
            this.Name = reader.ReadBlockAt <string_r>(
                this.NamePointer                 // offset
                );
            this.Unknown_60h_Data = reader.ReadBlockAt <ResourcePointerArray64 <Unknown_F_011> >(
                this.Unknown_60h_Pointer,                 // offset
                this.Count1
                );
            this.Unknown_A8h_Data = reader.ReadBlockAt <Unknown_F_004>(
                this.Unknown_A8h_Pointer                 // offset
                );
            this.Unknown_E0h_Data = reader.ReadBlockAt <ResourcePointerArray64 <Unknown_F_006> >(
                this.Unknown_E0h_Pointer,                 // offset
                this.Count3
                );
            this.PhysicsLODGroup = reader.ReadBlockAt <FragPhysicsLODGroup_GTA5_pc>(
                this.PhysicsLODGroupPointer                 // offset
                );
            this.Unknown_F8h_Data = reader.ReadBlockAt <FragDrawable_GTA5_pc>(
                this.Unknown_F8h_Pointer                 // offset
                );
            this.LightAttributes = reader.ReadBlockAt <ResourceSimpleArray <LightAttributes_GTA5_pc> >(
                this.LightAttributesPointer,                 // offset
                this.LightAttributesCount
                );
            this.Unknown_120h_Data = reader.ReadBlockAt <Unknown_F_003>(
                this.Unknown_120h_Pointer                 // offset
                );
        }