public CBitmapTexture(CR2WFile cr2w, CVariable parent, string name) : base(cr2w, parent, name)
        {
            MipsCount = new CUInt32(cr2w, this, nameof(MipsCount))
            {
                IsSerialized = true
            };
            Mipdata = new CCompressedBuffer <SMipData>(cr2w, this, nameof(Mipdata))
            {
                IsSerialized = true
            };
            unk1 = new CUInt16(cr2w, this, nameof(unk1))
            {
                IsSerialized = true
            };
            unk2 = new CUInt16(cr2w, this, nameof(unk2))
            {
                IsSerialized = true
            };

            ResidentmipSize = new CUInt32(cr2w, this, nameof(ResidentmipSize))
            {
                IsSerialized = true
            };
            Residentmip = new CBytes(cr2w, this, nameof(Residentmip))
            {
                IsSerialized = true
            };
        }
Example #2
0
        public override void Write(BinaryWriter file)
        {
            CUInt32 count = new CUInt32(cr2w, null, "")
            {
                val = (uint)Elements.Count
            };

            count.Write(file);

            base.Write(file);
        }
Example #3
0
        public override void Read(BinaryReader file, uint size)
        {
            base.Read(file, size);

            //lazy check if Cvariable is first chunk (= resource) or derived
            if (ParentVar != null || this is CSkeletalAnimationSet)
            {
                return;
            }
            Unk1 = new CUInt32(cr2w, this, nameof(Unk1))
            {
                IsSerialized = true
            };
            Unk1.Read(file, size);
        }
 public CPhysicalCollision(CR2WFile cr2w, CVariable parent, string name) : base(cr2w, parent, name)
 {
     Unk1 = new CUInt32(cr2w, this, nameof(Unk1))
     {
         IsSerialized = true
     };
     Data = new CBytes(cr2w, this, nameof(Data))
     {
         IsSerialized = true
     };
     Collisiontypes = new CBufferVLQInt32 <CName>(cr2w, this, nameof(Collisiontypes))
     {
         IsSerialized = true
     };
 }
 public SEntityBufferType2(CR2WFile cr2w, CVariable parent, string name) : base(cr2w, parent, name)
 {
     componentName = new CName(cr2w, this, nameof(componentName))
     {
         IsSerialized = true
     };
     sizeofdata = new CUInt32(cr2w, this, nameof(sizeofdata))
     {
         IsSerialized = true
     };
     variables = new CBufferUInt32 <CVariantSizeTypeName>(cr2w, this, nameof(variables))
     {
         IsSerialized = true
     };
 }