Beispiel #1
0
 public ActorCollisionData(MpqFileStream stream)
 {
     ColFlags = new ActorCollisionFlags(stream);
     I0       = stream.ReadValueS32();
     Cylinder = new AxialCylinder(stream);
     AABB     = new AABB(stream);
     F0       = stream.ReadValueF32();
     stream.ReadValueS32();// Testing - DarkLotus
 }
Beispiel #2
0
        public Actor(MpqFile file)
        {
            var stream = file.Open();
            Header = new Header(stream);

            this.Int0 = stream.ReadValueS32();
            this.Type = (ActorType)stream.ReadValueS32();
            this.ApperanceSNO = stream.ReadValueS32();
            this.PhysMeshSNO = stream.ReadValueS32();
            this.Cylinder = new AxialCylinder(stream);
            this.Sphere = new Sphere(stream);
            this.AABBBounds = new AABB(stream);

            var tagmap = stream.GetSerializedDataPointer(); // we need to read tagmap. /raist.
            stream.Position += (2*4);

            this.AnimSetSNO = stream.ReadValueS32();
            this.MonsterSNO = stream.ReadValueS32();

            var msgTriggeredEvents = stream.GetSerializedDataPointer();

            this.Int1 = stream.ReadValueS32();
            stream.Position += (3*4);
            this.V0 = new Vector3D(stream.ReadValueF32(), stream.ReadValueF32(), stream.ReadValueF32());

            this.Looks = new WeightedLook[8];
            for (int i = 0; i < 8; i++)
            {
                this.Looks[i] = new WeightedLook(stream);
            }

            this.PhysicsSNO = stream.ReadValueS32();
            this.Int2 = stream.ReadValueS32();
            this.Int3 = stream.ReadValueS32();
            this.Float0 = stream.ReadValueF32();
            this.Float1 = stream.ReadValueF32();
            this.Float2 = stream.ReadValueF32();

            this.ActorCollisionData = new int[17]; // Was 68/4 - Darklotus 
            for (int i = 0; i < 17; i++)
            {
                this.ActorCollisionData[i] = stream.ReadValueS32();
            }

            this.InventoryImages = new int[10]; //Was 5*8/4 - Darklotus
            for (int i = 0; i < 10; i++)
            {
                this.InventoryImages[i] = stream.ReadValueS32();
            }

            // Updated based on BoyC's 010editoer template, looks like some data at the end still isnt parsed - Darklotus
            stream.Close();
        }
Beispiel #3
0
        // Updated based on BoyC's 010editoer template, looks like some data at the end still isnt parsed - Darklotus
        public Actor(MpqFile file)
        {
            var stream = file.Open();
            stream.Seek(16, SeekOrigin.Begin);
            this.ActorSNO = stream.ReadInt32();
            stream.Position += 8; // pad 2;
            this.i0 = stream.ReadInt32();
            this.Type = stream.ReadInt32();
            this.ApperanceSNO = stream.ReadInt32();
            this.snoPhysMesh = stream.ReadInt32();
            this.Cyl = new AxialCylinder(stream);
            this.s = new Sphere(stream);
            this.aabbBounds = new AABB(stream);
            this.serTagMap = new SerializeData(stream);
            stream.Position += 8; // pad 2
            this.AnimSetSNO = stream.ReadInt32();
            this.MonsterSNO = stream.ReadInt32();
            this.serMsgTriggeredEvents = new SerializeData(stream);

            this.i1 = stream.ReadInt32();
            stream.Position += 12; // pad 3 int - DarkLotus
            this.v0 = new Vector3D(stream.ReadFloat(), stream.ReadFloat(), stream.ReadFloat());
            this.Looks = new WeightedLook[8];
            for (int i = 0; i < 8; i++)
            {
                this.Looks[i] = new WeightedLook(stream);
            }
            this.PhysicsSNO = stream.ReadInt32();
            this.i2 = stream.ReadInt32(); this.i3 = stream.ReadInt32();
            this.f0 = stream.ReadFloat(); this.f1 = stream.ReadFloat(); this.f2 = stream.ReadFloat();
            this.padActorCollisionData = new int[17]; // Was 68/4 - Darklotus 
            for (int i = 0; i < 17; i++)
            {
                this.padActorCollisionData[i] = stream.ReadInt32();
            }
            this.padInventoryImages = new int[10]; //Was 5*8/4 - Darklotus
            for (int i = 0; i < 10; i++)
            {
                this.padInventoryImages[i] = stream.ReadInt32();
            }
            stream.Close();
        }
Beispiel #4
0
 public ActorCollisionData(MpqFileStream stream)
 {
     ColFlags = new ActorCollisionFlags(stream);
     I0 = stream.ReadValueS32();
     Cylinder = new AxialCylinder(stream);
     AABB = new AABB(stream);
     F0 = stream.ReadValueF32();
     stream.ReadValueS32();// Testing - DarkLotus
 }