示例#1
0
        public bool ReadFromBinary(BinaryTable table, int index)
        {
            LevelMonsterRecord record = GetRecord(table, index);

            group    = DataRecordUtility.ExtractInt(table, record.group, 0);
            scene    = DataRecordUtility.ExtractInt(table, record.scene, 0);
            camp     = DataRecordUtility.ExtractInt(table, record.camp, 0);
            actorID  = DataRecordUtility.ExtractInt(table, record.actorID, 0);
            x        = DataRecordUtility.ExtractFloat(table, record.x, 0);
            y        = DataRecordUtility.ExtractFloat(table, record.y, 0);
            dir      = DataRecordUtility.ExtractFloat(table, record.dir, 0);
            level    = DataRecordUtility.ExtractInt(table, record.level, 0);
            passive  = DataRecordUtility.ExtractBool(table, record.passive, false);
            aiLogic  = DataRecordUtility.ExtractString(table, record.aiLogic, "");
            aiParams = DataRecordUtility.ExtractStringList(table, record.aiParams, null);
            return(true);
        }
        public bool ReadFromBinary(BinaryTable table, int index)
        {
            SkillRecord record = GetRecord(table, index);

            id                      = DataRecordUtility.ExtractInt(table, record.id, 0);
            desc                    = DataRecordUtility.ExtractString(table, record.desc, "");
            type                    = DataRecordUtility.ExtractInt(table, record.type, 0);
            icon                    = DataRecordUtility.ExtractInt(table, record.icon, 0);
            distance                = DataRecordUtility.ExtractFloat(table, record.distance, 0);
            cooldown                = DataRecordUtility.ExtractFloat(table, record.cooldown, 0);
            BaseCooldown            = DataRecordUtility.ExtractFloat(table, record.BaseCooldown, 0);
            duration                = DataRecordUtility.ExtractFloat(table, record.duration, 0);
            interval                = DataRecordUtility.ExtractFloat(table, record.interval, 0);
            damage                  = DataRecordUtility.ExtractInt(table, record.damage, 0);
            mpRecover               = DataRecordUtility.ExtractInt(table, record.mpRecover, 0);
            hpRecover               = DataRecordUtility.ExtractInt(table, record.hpRecover, 0);
            addAttack               = DataRecordUtility.ExtractInt(table, record.addAttack, 0);
            addShield               = DataRecordUtility.ExtractInt(table, record.addShield, 0);
            addSpeed                = DataRecordUtility.ExtractFloat(table, record.addSpeed, 0);
            canmove                 = DataRecordUtility.ExtractInt(table, record.canmove, 0);
            leadAnim                = DataRecordUtility.ExtractString(table, record.leadAnim, "");
            leadAnimTime            = DataRecordUtility.ExtractInt(table, record.leadAnimTime, 0);
            leadEffect              = DataRecordUtility.ExtractString(table, record.leadEffect, "");
            leadEffectBone          = DataRecordUtility.ExtractString(table, record.leadEffectBone, "");
            leadEffectStartTime     = DataRecordUtility.ExtractInt(table, record.leadEffectStartTime, 0);
            leadEffectDeleteTime    = DataRecordUtility.ExtractInt(table, record.leadEffectDeleteTime, 0);
            castAnim                = DataRecordUtility.ExtractString(table, record.castAnim, "");
            castAnimTime            = DataRecordUtility.ExtractInt(table, record.castAnimTime, 0);
            selfEffect              = DataRecordUtility.ExtractString(table, record.selfEffect, "");
            selfEffectBone          = DataRecordUtility.ExtractString(table, record.selfEffectBone, "");
            selfEffectStartTime     = DataRecordUtility.ExtractInt(table, record.selfEffectStartTime, 0);
            selfEffectDeleteTime    = DataRecordUtility.ExtractInt(table, record.selfEffectDeleteTime, 0);
            targetEffect            = DataRecordUtility.ExtractString(table, record.targetEffect, "");
            targetEffectBone        = DataRecordUtility.ExtractString(table, record.targetEffectBone, "");
            targetEffectStartTime   = DataRecordUtility.ExtractInt(table, record.targetEffectStartTime, 0);
            targetEffectDeleteTime  = DataRecordUtility.ExtractInt(table, record.targetEffectDeleteTime, 0);
            emitEffect              = DataRecordUtility.ExtractString(table, record.emitEffect, "");
            emitEffectBone          = DataRecordUtility.ExtractString(table, record.emitEffectBone, "");
            emitEffectStartTime     = DataRecordUtility.ExtractInt(table, record.emitEffectStartTime, 0);
            emitSpeed               = DataRecordUtility.ExtractInt(table, record.emitSpeed, 0);
            hitAnim                 = DataRecordUtility.ExtractString(table, record.hitAnim, "");
            hitAnimTime             = DataRecordUtility.ExtractInt(table, record.hitAnimTime, 0);
            hitEffect               = DataRecordUtility.ExtractString(table, record.hitEffect, "");
            hitEffectBone           = DataRecordUtility.ExtractString(table, record.hitEffectBone, "");
            hitEffectStartTime      = DataRecordUtility.ExtractInt(table, record.hitEffectStartTime, 0);
            hitEffectDeleteTime     = DataRecordUtility.ExtractInt(table, record.hitEffectDeleteTime, 0);
            impactToSelf            = DataRecordUtility.ExtractInt(table, record.impactToSelf, 0);
            impactToTarget          = DataRecordUtility.ExtractInt(table, record.impactToTarget, 0);
            interruptPriority       = DataRecordUtility.ExtractInt(table, record.interruptPriority, 0);
            isInterrupt             = DataRecordUtility.ExtractBool(table, record.isInterrupt, false);
            targetType              = DataRecordUtility.ExtractInt(table, record.targetType, 0);
            aoeType                 = DataRecordUtility.ExtractInt(table, record.aoeType, 0);
            aoeSize                 = DataRecordUtility.ExtractFloat(table, record.aoeSize, 0);
            aoeAngleOrLength        = DataRecordUtility.ExtractFloat(table, record.aoeAngleOrLength, 0);
            maxAoeTargetCount       = DataRecordUtility.ExtractInt(table, record.maxAoeTargetCount, 0);
            dslSkillId              = DataRecordUtility.ExtractInt(table, record.dslSkillId, 0);
            dslFile                 = DataRecordUtility.ExtractString(table, record.dslFile, "");
            sound                   = DataRecordUtility.ExtractString(table, record.sound, "");
            soundDelay              = DataRecordUtility.ExtractInt(table, record.soundDelay, 0);
            skilltimescale          = DataRecordUtility.ExtractFloat(table, record.skilltimescale, 0);
            skilltimescalestarttime = DataRecordUtility.ExtractInt(table, record.skilltimescalestarttime, 0);
            skilltimescaleendtime   = DataRecordUtility.ExtractInt(table, record.skilltimescaleendtime, 0);
            return(true);
        }