Example #1
0
 public void Deserialize(SaveStream input)
 {
     this.Name         = input.ReadString();
     this.Level        = input.ReadValueU32();
     this.Experience   = input.ReadValueU32();
     this.ArtifactMode = input.ReadValueS32();
 }
Example #2
0
 public void Deserialize(SaveStream input)
 {
     this.Grade        = input.ReadString();
     this.Type         = input.ReadString();
     this.Body         = input.ReadString();
     this.LeftSide     = input.ReadString();
     this.RightSide    = input.ReadString();
     this.Material     = input.ReadString();
     this.Manufacturer = input.ReadString();
     this.Prefix       = input.ReadString();
     this.Title        = input.ReadString();
     this.Unknown09    = input.ReadValueU32();
     this.Quality      = input.ReadValueU32();
     this.Equipped     = input.ReadValueU32();
 }
        public void Deserialize(SaveStream input)
        {
            this.Playthrough = input.ReadValueU32();

            // Echos
            {
                uint count = input.ReadValueU32();
                this.Echoes.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Echo echo = new Echo();
                    echo.Deserialize(input);
                    this.Echoes.Add(echo);
                }
            }
        }
        public void Deserialize(SaveStream input)
        {
            this.Playthrough   = input.ReadValueU32();
            this.ActiveMission = input.ReadString();

            // Missions
            {
                uint count = input.ReadValueU32();
                this.Missions.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Mission mission = new Mission();
                    mission.Deserialize(input);
                    this.Missions.Add(mission);
                }
            }
        }
Example #5
0
        public void Deserialize(SaveStream input)
        {
            this.Name     = input.ReadString();
            this.Unknown1 = input.ReadValueU32();
            this.Unknown2 = input.ReadValueU32();
            this.Unknown3 = input.ReadValueU32();

            // States
            {
                uint count = input.ReadValueU32();
                this.Unknown4s.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Unknown4 unknown3 = new Unknown4();
                    unknown3.Deserialize(input);
                    this.Unknown4s.Add(unknown3);
                }
            }
        }
Example #6
0
 public void Deserialize(SaveStream input)
 {
     this.Grade        = input.ReadString();
     this.Manufacturer = input.ReadString();
     this.Type         = input.ReadString();
     this.Body         = input.ReadString();
     this.Grip         = input.ReadString();
     this.Magazine     = input.ReadString();
     this.Barrel       = input.ReadString();
     this.Sight        = input.ReadString();
     this.Stock        = input.ReadString();
     this.Action       = input.ReadString();
     this.Accessory    = input.ReadString();
     this.Material     = input.ReadString();
     this.Prefix       = input.ReadString();
     this.Title        = input.ReadString();
     this.ClipSize     = input.ReadValueU32();
     this.Quality      = input.ReadValueU32();
     this.EquipSlot    = input.ReadValueU32();
 }
Example #7
0
        public void Deserialize(SaveStream input)
        {
            if (input.ReadStaticString(4) != "PLYR")
            {
                throw new FormatException("not player data");
            }

            this.Version = input.ReadValueU32();
            if (this.Version != 35)
            {
                throw new FormatException("unsupported player data version (" + this.Version.ToString() + ")");
            }

            this.Character   = input.ReadString();
            this.Level       = input.ReadValueU32();
            this.Experience  = input.ReadValueU32();
            this.SkillPoints = input.ReadValueU32();
            this.Unknown03   = input.ReadValueU32();
            this.Money       = input.ReadValueU32();
            this.MaybePlaythroughUnlocked = input.ReadValueU32();

            // Skills
            {
                uint count = input.ReadValueU32();
                this.Skills.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Skill skill = new Skill();
                    skill.Deserialize(input);
                    this.Skills.Add(skill);
                }
            }

            this.Unknown07 = input.ReadValueU32();
            this.Unknown08 = input.ReadValueU32();
            this.Unknown09 = input.ReadValueU32();
            this.Unknown10 = input.ReadValueU32();

            // Ammo Pools
            {
                uint count = input.ReadValueU32();
                this.AmmoPools.Clear();
                for (uint i = 0; i < count; i++)
                {
                    AmmoPool pool = new AmmoPool();
                    pool.Deserialize(input);
                    this.AmmoPools.Add(pool);
                }
            }

            // Items
            {
                uint count = input.ReadValueU32();
                this.Items.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Item item = new Item();
                    item.Deserialize(input);
                    this.Items.Add(item);
                }
            }

            this.BackpackSlots = input.ReadValueU32();
            this.WeaponSlots   = input.ReadValueU32();

            // Weapons
            {
                uint count = input.ReadValueU32();
                this.Weapons.Clear();
                for (uint i = 0; i < count; i++)
                {
                    Weapon weapon = new Weapon();
                    weapon.Deserialize(input);
                    this.Weapons.Add(weapon);
                }
            }

            this.Stats = input.ReadBuffer();

            // Visited Zones
            {
                uint count = input.ReadValueU32();
                this.VisitedStations.Clear();
                for (uint i = 0; i < count; i++)
                {
                    this.VisitedStations.Add(input.ReadString());
                }
            }

            this.CurrentStation = input.ReadString();

            // Unknown19
            {
                uint count = input.ReadValueU32();
                if (count != 0)
                {
                    throw new Exception();
                }
            }

            // Unknown20
            {
                uint count = input.ReadValueU32();
                if (count != 0)
                {
                    throw new Exception();
                }
            }

            this.Unknown21        = input.ReadString();;
            this.Unknown22        = input.ReadValueU32();
            this.Unknown23        = input.ReadValueU32();
            this.SaveSlot         = input.ReadValueU32();
            this.ExtraDataVersion = input.ReadValueU32();

            if (this.ExtraDataVersion >= 27)
            {
                this.Unknown26 = input.ReadValueU32();
            }

            if (this.ExtraDataVersion >= 28 && this.ExtraDataVersion <= 31)
            {
                // junk
                input.ReadString();

                {
                    uint count = input.ReadValueU32();
                    for (uint i = 0; i < count; i++)
                    {
                        input.ReadString();
                    }
                }
            }

            if (this.ExtraDataVersion >= 29)
            {
                // Mission Zones
                {
                    uint count = input.ReadValueU32();
                    this.MissionPlaythroughs.Clear();
                    for (uint i = 0; i < count; i++)
                    {
                        MissionPlaythrough missionZone = new MissionPlaythrough();
                        missionZone.Deserialize(input);
                        this.MissionPlaythroughs.Add(missionZone);
                    }
                }
            }

            if (this.ExtraDataVersion >= 30)
            {
                this.PlayTime = input.ReadValueU32();
                this.SaveTime = input.ReadString();
            }

            if (this.ExtraDataVersion >= 31)
            {
                this.Name   = input.ReadString();
                this.Color1 = input.ReadValueU32();
                this.Color2 = input.ReadValueU32();
                this.Color3 = input.ReadValueU32();
            }

            if (this.ExtraDataVersion >= 32)
            {
                this.Unknown34 = input.ReadValueU32();

                // Unknown35
                {
                    uint count = input.ReadValueU32();
                    this.Unknown35.Clear();
                    for (uint i = 0; i < count; i++)
                    {
                        this.Unknown35.Add(input.ReadValueU32());
                    }
                }
            }

            if (this.ExtraDataVersion >= 33)
            {
                // Unknown36
                {
                    uint count = input.ReadValueU32();
                    this.Unknown36.Clear();
                    for (uint i = 0; i < count; i++)
                    {
                        this.Unknown36.Add(input.ReadValueU32());
                    }
                }
            }

            if (this.ExtraDataVersion >= 34)
            {
                // Echo Zones
                {
                    uint count = input.ReadValueU32();
                    this.EchoPlaythroughs.Clear();
                    for (uint i = 0; i < count; i++)
                    {
                        EchoPlaythrough echoZone = new EchoPlaythrough();
                        echoZone.Deserialize(input);
                        this.EchoPlaythroughs.Add(echoZone);
                    }
                }
            }

            if (this.ExtraDataVersion >= 35)
            {
                // Unknown38
                this.Unknown38 = input.ReadBuffer();
            }
        }
 public void Deserialize(SaveStream input)
 {
     this.Name     = input.ReadString();
     this.Unknown1 = input.ReadValueU32();
     this.Unknown2 = input.ReadValueU32();
 }