예제 #1
0
        public override void Deserialize(IDataReader reader)
        {
            var flag = reader.ReadByte();

            Sex                = BooleanByteWrapper.GetFlag(flag, 0);
            IsRideable         = BooleanByteWrapper.GetFlag(flag, 1);
            IsWild             = BooleanByteWrapper.GetFlag(flag, 2);
            IsFecondationReady = BooleanByteWrapper.GetFlag(flag, 3);
            UseHarnessColors   = BooleanByteWrapper.GetFlag(flag, 4);
            ObjectId           = reader.ReadDouble();
            Model              = reader.ReadVarUhInt();
            var ancestorCount = reader.ReadUShort();

            Ancestor = new List <int>();
            for (var ancestorIndex = 0; ancestorIndex < ancestorCount; ancestorIndex++)
            {
                Ancestor.Add(reader.ReadInt());
            }
            var behaviorsCount = reader.ReadUShort();

            Behaviors = new List <int>();
            for (var behaviorsIndex = 0; behaviorsIndex < behaviorsCount; behaviorsIndex++)
            {
                Behaviors.Add(reader.ReadInt());
            }
            Name                   = reader.ReadUTF();
            OwnerId                = reader.ReadInt();
            Experience             = reader.ReadVarUhLong();
            ExperienceForLevel     = reader.ReadVarUhLong();
            ExperienceForNextLevel = reader.ReadDouble();
            Level                  = reader.ReadByte();
            MaxPods                = reader.ReadVarUhInt();
            Stamina                = reader.ReadVarUhInt();
            StaminaMax             = reader.ReadVarUhInt();
            Maturity               = reader.ReadVarUhInt();
            MaturityForAdult       = reader.ReadVarUhInt();
            Energy                 = reader.ReadVarUhInt();
            EnergyMax              = reader.ReadVarUhInt();
            Serenity               = reader.ReadInt();
            AggressivityMax        = reader.ReadInt();
            SerenityMax            = reader.ReadVarUhInt();
            Love                   = reader.ReadVarUhInt();
            LoveMax                = reader.ReadVarUhInt();
            FecondationTime        = reader.ReadInt();
            BoostLimiter           = reader.ReadInt();
            BoostMax               = reader.ReadDouble();
            ReproductionCount      = reader.ReadInt();
            ReproductionCountMax   = reader.ReadVarUhInt();
            HarnessGID             = reader.ReadVarUhShort();
            var effectListCount = reader.ReadUShort();

            EffectList = new List <ObjectEffectInteger>();
            for (var effectListIndex = 0; effectListIndex < effectListCount; effectListIndex++)
            {
                var objectToAdd = new ObjectEffectInteger();
                objectToAdd.Deserialize(reader);
                EffectList.Add(objectToAdd);
            }
        }
예제 #2
0
        public override void Deserialize(ICustomDataInput reader)
        {
            Owner = new CharacterMinimalInformations();
            Owner.Deserialize(reader);
            var countBonuses = reader.ReadShort();

            Bonuses = new List <ObjectEffectInteger>();
            for (short i = 0; i < countBonuses; i++)
            {
                ObjectEffectInteger type = new ObjectEffectInteger();
                type.Deserialize(reader);
                Bonuses.Add(type);
            }
            Bugdet = reader.ReadVarInt();
            Saved  = reader.ReadBoolean();
        }
예제 #3
0
        public override void Deserialize(IDataReader reader)
        {
            Owner = new CharacterMinimalInformations();
            Owner.Deserialize(reader);
            var BonusesCount = reader.ReadShort();

            Bonuses = new List <ObjectEffectInteger>();
            for (var i = 0; i < BonusesCount; i++)
            {
                var objectToAdd = new ObjectEffectInteger();
                objectToAdd.Deserialize(reader);
                Bonuses.Add(objectToAdd);
            }
            Bugdet = reader.ReadVarUhInt();
            Saved  = reader.ReadBoolean();
        }
예제 #4
0
        public override void Deserialize(IDataReader reader)
        {
            this.owner = new CharacterMinimalInformations();
            this.owner.Deserialize(reader);
            uint num = (uint)reader.ReadUShort();

            for (int index = 0; (long)index < (long)num; ++index)
            {
                ObjectEffectInteger objectEffectInteger = new ObjectEffectInteger();
                objectEffectInteger.Deserialize(reader);
                this.bonuses.Add(objectEffectInteger);
            }
            this.bugdet = reader.ReadVarUhInt();
            if (this.bugdet < 0U)
            {
                throw new Exception("Forbidden value (" + (object)this.bugdet + ") on element of BreachStateMessage.bugdet.");
            }
            this.saved = reader.ReadBoolean();
        }
예제 #5
0
        public override void Deserialize(ICustomDataInput reader)
        {
            byte flag = reader.ReadByte();

            m_sex                = BooleanByteWrapper.GetFlag(flag, 0);
            m_isRideable         = BooleanByteWrapper.GetFlag(flag, 1);
            m_isWild             = BooleanByteWrapper.GetFlag(flag, 2);
            m_isFecondationReady = BooleanByteWrapper.GetFlag(flag, 3);
            m_useHarnessColors   = BooleanByteWrapper.GetFlag(flag, 4);
            m_ObjectId           = reader.ReadDouble();
            m_model              = reader.ReadVarUhInt();
            int ancestorCount = reader.ReadUShort();
            int ancestorIndex;

            m_ancestor = new System.Collections.Generic.List <int>();
            for (ancestorIndex = 0; (ancestorIndex < ancestorCount); ancestorIndex = (ancestorIndex + 1))
            {
                m_ancestor.Add(reader.ReadInt());
            }
            int behaviorsCount = reader.ReadUShort();
            int behaviorsIndex;

            m_behaviors = new System.Collections.Generic.List <int>();
            for (behaviorsIndex = 0; (behaviorsIndex < behaviorsCount); behaviorsIndex = (behaviorsIndex + 1))
            {
                m_behaviors.Add(reader.ReadInt());
            }
            m_name                   = reader.ReadUTF();
            m_ownerId                = reader.ReadInt();
            m_experience             = reader.ReadVarUhLong();
            m_experienceForLevel     = reader.ReadVarUhLong();
            m_experienceForNextLevel = reader.ReadDouble();
            m_level                  = reader.ReadByte();
            m_maxPods                = reader.ReadVarUhInt();
            m_stamina                = reader.ReadVarUhInt();
            m_staminaMax             = reader.ReadVarUhInt();
            m_maturity               = reader.ReadVarUhInt();
            m_maturityForAdult       = reader.ReadVarUhInt();
            m_energy                 = reader.ReadVarUhInt();
            m_energyMax              = reader.ReadVarUhInt();
            m_serenity               = reader.ReadInt();
            m_aggressivityMax        = reader.ReadInt();
            m_serenityMax            = reader.ReadVarUhInt();
            m_love                   = reader.ReadVarUhInt();
            m_loveMax                = reader.ReadVarUhInt();
            m_fecondationTime        = reader.ReadInt();
            m_boostLimiter           = reader.ReadInt();
            m_boostMax               = reader.ReadDouble();
            m_reproductionCount      = reader.ReadInt();
            m_reproductionCountMax   = reader.ReadVarUhInt();
            m_harnessGID             = reader.ReadVarUhShort();
            int effectListCount = reader.ReadUShort();
            int effectListIndex;

            m_effectList = new System.Collections.Generic.List <ObjectEffectInteger>();
            for (effectListIndex = 0; (effectListIndex < effectListCount); effectListIndex = (effectListIndex + 1))
            {
                ObjectEffectInteger objectToAdd = new ObjectEffectInteger();
                objectToAdd.Deserialize(reader);
                m_effectList.Add(objectToAdd);
            }
        }
예제 #6
0
 public override void Deserialize(IDataReader reader)
 {
     Bonus = new ObjectEffectInteger();
     Bonus.Deserialize(reader);
 }
예제 #7
0
 public override void Deserialize(ICustomDataInput reader)
 {
     Bonus = new ObjectEffectInteger();
     Bonus.Deserialize(reader);
 }