コード例 #1
0
ファイル: Skill.cs プロジェクト: isoundy000/wzry-1
        private void SetSkillSpeed(PoolObjHandle <ActorRoot> user)
        {
            int           totalValue = 0;
            int           num2       = 0;
            int           num3       = 0;
            ValueDataInfo info       = null;

            if (base.curAction != 0)
            {
                info       = user.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_PROPERTY_ATTACKSPEED];
                totalValue = info.totalValue;
                num3       = (int)((totalValue + (user.handle.ValueComponent.mActorValue.actorLvl * this.battleParam.dwM_AttackSpeed)) + this.battleParam.dwN_AttackSpeed);
                if (num3 != 0)
                {
                    num2 = (totalValue * 0x2710) / num3;
                }
                num2 += user.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_ATKSPDADD].totalValue;
                if ((this.cfgData != null) && (this.cfgData.bNoInfluenceAnim == 1))
                {
                    num2 = 0;
                }
                VFactor factor = new VFactor((long)(0x2710 + num2), 0x2710L);
                this.curAction.handle.SetPlaySpeed(factor);
            }
        }
コード例 #2
0
 public void ChangeFuncEft(RES_FUNCEFT_TYPE key, RES_VALUE_TYPE type, int val, bool bOffRatio = false)
 {
     if (this.mActorValue[key] != null)
     {
         ValueDataInfo.ChangeValueData(ref this.mActorValue[key], type, val, bOffRatio);
     }
 }
コード例 #3
0
        public int EpProportionCalculator(ValueDataInfo vd, int baseValue)
        {
            int  num  = (baseValue / 0x2710) + (((this.SoulLevel - 1) * vd.growValue) / 0x2710);
            long num2 = ((((num + vd.addValue) - vd.decValue) * ((0x2710 + vd.addRatio) - vd.decRatio)) / 0x2710L) + vd.addValueOffRatio;

            return((int)num2);
        }
コード例 #4
0
ファイル: OrganWrapper.cs プロジェクト: TonyDongGuaPi/joework
        public override void Fight()
        {
            base.Fight();
            this.AddNoAbilityFlag(ObjAbilityType.ObjAbility_Move);
            this.AddNoAbilityFlag(ObjAbilityType.ObjAbility_ImmuneCrit);
            FrameCommand <AttackPositionCommand> frameCommand = FrameCommandFactory.CreateFrameCommand <AttackPositionCommand>();

            frameCommand.cmdId            = 1u;
            frameCommand.cmdData.WorldPos = this.actor.location;
            base.CmdAttackMoveToDest(frameCommand, this.actor.location);
            if (this.isTower)
            {
                this.HitEffect.Reset(this);
            }
            this.actor.ValueComponent.mActorValue[34].baseValue = this.actor.TheStaticData.TheOrganOnlyInfo.PhyArmorHurtRate;
            this._aroundEnemyMonsterCount = 0;
            ValueDataInfo valueDataInfo = this.actor.ValueComponent.mActorValue[3] + this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddPhyDef;

            valueDataInfo = this.actor.ValueComponent.mActorValue[4] + this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddMgcDef;
            if (this.actor.HorizonMarker != null)
            {
                if (FogOfWar.enable)
                {
                    if (this.GetActorSubType() == 1 || this.GetActorSubType() == 4)
                    {
                        this.actor.HorizonMarker.SightRadius = Horizon.QueryFowTowerSightRadius();
                    }
                    this.TarEyeList_ = new List <PoolObjHandle <ActorRoot> >();
                }
                else
                {
                    this.actor.HorizonMarker.SightRadius = this.actor.TheStaticData.TheOrganOnlyInfo.HorizonRadius;
                }
            }
        }
コード例 #5
0
 private void ActorMarkProcess(PoolObjHandle <ActorRoot> _inActor, AreaCheck.ActorAction _action)
 {
     if (_inActor != 0)
     {
         if (_inActor.handle.TheActorMeta.ActorType == ActorTypeDef.Actor_Type_Monster)
         {
             if (_action == AreaCheck.ActorAction.Enter)
             {
                 if (++this._aroundEnemyMonsterCount == 1)
                 {
                     ValueDataInfo info = base.actor.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYDEFPT] - base.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddPhyDef;
                     info = base.actor.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCDEFPT] - base.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddMgcDef;
                 }
             }
             else if ((_action == AreaCheck.ActorAction.Leave) && (--this._aroundEnemyMonsterCount == 0))
             {
                 ValueDataInfo info2 = base.actor.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYDEFPT] + base.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddPhyDef;
                 info2 = base.actor.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCDEFPT] + base.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddMgcDef;
             }
         }
         else if (_inActor.handle.TheActorMeta.ActorType == ActorTypeDef.Actor_Type_Hero)
         {
             if (_action == AreaCheck.ActorAction.Enter)
             {
                 _inActor.handle.HorizonMarker.AddShowMark(COM_PLAYERCAMP.COM_PLAYERCAMP_COUNT, HorizonConfig.ShowMark.Skill, 1);
             }
             else if (_action == AreaCheck.ActorAction.Leave)
             {
                 _inActor.handle.HorizonMarker.AddShowMark(COM_PLAYERCAMP.COM_PLAYERCAMP_COUNT, HorizonConfig.ShowMark.Skill, -1);
             }
         }
     }
 }
コード例 #6
0
        public int EpProportionCalculator(ValueDataInfo vd, int baseValue)
        {
            int  num  = baseValue / 10000 + (this.SoulLevel - 1) * vd.growValue / 10000;
            long num2 = (long)(num + vd.addValue - vd.decValue) * (long)(10000 + vd.addRatio - vd.decRatio) / 10000L + (long)vd.addValueOffRatio;

            return((int)num2);
        }
コード例 #7
0
        private void SetSkillSpeed(PoolObjHandle <ActorRoot> _user)
        {
            int num = 0;

            if (this.curAction)
            {
                PoolObjHandle <ActorRoot> poolObjHandle  = _user;
                MonsterWrapper            monsterWrapper = _user.handle.ActorControl as MonsterWrapper;
                if (monsterWrapper != null && monsterWrapper.isCalledMonster && monsterWrapper.UseHostValueProperty)
                {
                    poolObjHandle = monsterWrapper.hostActor;
                }
                ValueDataInfo valueDataInfo = poolObjHandle.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_PROPERTY_ATTACKSPEED];
                int           totalValue    = valueDataInfo.totalValue;
                int           num2          = totalValue + poolObjHandle.handle.ValueComponent.mActorValue.actorLvl * (int)this.battleParam.dwM_AttackSpeed + (int)this.battleParam.dwN_AttackSpeed;
                if (num2 != 0)
                {
                    num = totalValue * 10000 / num2;
                }
                num += poolObjHandle.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_ATKSPDADD].totalValue;
                if (this.cfgData != null && this.cfgData.bNoInfluenceAnim == 1)
                {
                    num = 0;
                }
                VFactor playSpeed = new VFactor((long)(10000 + num), 10000L);
                this.curAction.handle.SetPlaySpeed(playSpeed);
            }
        }
コード例 #8
0
 public int EpRecCalculator(ValueDataInfo vd, ValueDataType type)
 {
     if (type == ValueDataType.TYPE_TOTAL)
     {
         return(this.EpProportionCalculator(vd, vd.baseValue));
     }
     return(this.EpBaseProportionCalculator(vd, vd.baseValue));
 }
コード例 #9
0
 public int DynamicAdjustor(ValueDataInfo vd, ValueDataType type)
 {
     if (type == ValueDataType.TYPE_TOTAL)
     {
         return(this.GenericCalculator(vd, DynamicProperty.Adjustor(vd)));
     }
     return(this.GenericBaseCalculator(vd, DynamicProperty.Adjustor(vd)));
 }
コード例 #10
0
 public int GrowCalculator(ValueDataInfo vd, ValueDataType type)
 {
     if (type == ValueDataType.TYPE_TOTAL)
     {
         return(this.GenericCalculator(vd, vd.baseValue));
     }
     return(this.GenericBaseCalculator(vd, vd.baseValue));
 }
コード例 #11
0
 public int EpGrowCalculator(ValueDataInfo vd, ValueDataType type)
 {
     if (type == ValueDataType.TYPE_TOTAL)
     {
         return(this.EpNumericalCalculator(vd, vd.baseValue));
     }
     return(this.EpBaseNumericalCalculator(vd, vd.baseValue));
 }
コード例 #12
0
 public static void SetPropValue(ValueDataInfo info, int balanceVal)
 {
     info.baseValue = balanceVal;
     info.growValue = 0;
     info.addValue  = 0;
     info.decValue  = 0;
     info.addRatio  = 0;
     info.decRatio  = 0;
 }
コード例 #13
0
 public int DynamicAdjustorForMgcEffect(ValueDataInfo vd, ValueDataType type)
 {
     if (type == ValueDataType.TYPE_TOTAL)
     {
         int num = this.GenericCalculator(vd, DynamicProperty.Adjustor(vd));
         return(num + vd.totalEftValueByMgc);
     }
     return(this.GenericBaseCalculator(vd, DynamicProperty.Adjustor(vd)));
 }
コード例 #14
0
        public void ChangePhyAtkByPhyDefence()
        {
            ValueDataInfo valueDataInfo = this.mActorValue[1];

            valueDataInfo.addValue -= valueDataInfo.totalAddValueByDefence;
            long num = (long)this.mActorValue[3].totalValue * (long)valueDataInfo.convertRatioByDefence / 10000L;

            valueDataInfo.totalAddValueByDefence = (int)num;
            valueDataInfo.addValue += valueDataInfo.totalAddValueByDefence;
        }
コード例 #15
0
        public void ChangePhyAtkByPhyDefence()
        {
            ValueDataInfo valueDataInfo = this.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYATKPT];

            valueDataInfo.addValue -= valueDataInfo.totalAddValueByDefence;
            long num = (long)this.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYDEFPT].totalValue * (long)valueDataInfo.convertRatioByDefence / 10000L;

            valueDataInfo.totalAddValueByDefence = (int)num;
            valueDataInfo.addValue += valueDataInfo.totalAddValueByDefence;
        }
コード例 #16
0
        public int GetSkillCDMax()
        {
            int num = this.SkillObj.cfgData.iCoolDown;

            if (this.SlotType == SkillSlotType.SLOT_SKILL_9 || this.SlotType == SkillSlotType.SLOT_SKILL_10)
            {
                if (this.Actor && this.Actor.handle.SkillControl.bZeroCd)
                {
                    num = 0;
                }
                return(num);
            }
            int num2 = this.skillLevel - 1;

            if (num2 < 0)
            {
                num2 = 0;
            }
            num += this.SkillObj.cfgData.iCoolDownGrowth * num2;
            if (this.Actor)
            {
                int           num3          = 0;
                ValueDataInfo valueDataInfo = this.Actor.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_CDREDUCE];
                DebugHelper.Assert(valueDataInfo != null, "Failed get value data");
                if (valueDataInfo == null)
                {
                    return(10);
                }
                if (valueDataInfo != null && this.SlotType != SkillSlotType.SLOT_SKILL_0 && this.SlotType != SkillSlotType.SLOT_SKILL_4 && this.SlotType != SkillSlotType.SLOT_SKILL_5 && this.SlotType != SkillSlotType.SLOT_SKILL_7)
                {
                    num3 = valueDataInfo.totalValue;
                }
                int num4 = num3 + this.changeSkillCDRate;
                if (valueDataInfo.maxLimitValue > 0)
                {
                    num4 = ((num4 > valueDataInfo.maxLimitValue) ? valueDataInfo.maxLimitValue : num4);
                }
                long num5 = (long)num * (10000L - (long)num4);
                num = (int)(num5 / 10000L);
            }
            num = ((num < 0) ? 0 : num);
            if (this.SlotType == SkillSlotType.SLOT_SKILL_0)
            {
                ValueDataInfo valueDataInfo2 = this.Actor.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_ATKSPDADD];
                DebugHelper.Assert(valueDataInfo2 != null, "Failed get value data skill 0");
                num = num * 10000 / (10000 + valueDataInfo2.totalValue);
                num = ((num < 0) ? 0 : num);
            }
            if (this.Actor && this.Actor.handle.SkillControl.bZeroCd && this.SlotType != SkillSlotType.SLOT_SKILL_0)
            {
                num = 0;
            }
            return(num);
        }
コード例 #17
0
        public int GenericCalculator(ValueDataInfo vd, int baseValue)
        {
            int  num  = baseValue + (((this.SoulLevel - 1) * vd.growValue) / 0x2710);
            long num2 = ((((num + vd.addValue) - vd.decValue) * ((0x2710 + vd.addRatio) - vd.decRatio)) / 0x2710L) + vd.addValueOffRatio;

            if (vd.maxLimitValue > 0)
            {
                num2 = (num2 <= vd.maxLimitValue) ? num2 : ((long)vd.maxLimitValue);
            }
            return((int)num2);
        }
コード例 #18
0
        public int GenericCalculator(ValueDataInfo vd, int baseValue)
        {
            int  num  = baseValue + (this.SoulLevel - 1) * vd.growValue / 10000;
            long num2 = (long)(num + vd.addValue - vd.decValue) * (long)(10000 + vd.addRatio - vd.decRatio) / 10000L + (long)vd.addValueOffRatio;

            if (vd.maxLimitValue > 0)
            {
                num2 = ((num2 <= (long)vd.maxLimitValue) ? num2 : ((long)vd.maxLimitValue));
            }
            return((int)num2);
        }
コード例 #19
0
        public void IncAttackWithExtraHP()
        {
            ValueDataInfo valueDataInfo = this.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYATKPT];

            valueDataInfo.addValue -= valueDataInfo.totalAddValueByExtraHP;
            ValueDataInfo valueDataInfo2 = this.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_MAXHP];
            int           num            = valueDataInfo2.totalValue - valueDataInfo2.baseValue - valueDataInfo2.growValue;
            long          num2           = (long)num * (long)valueDataInfo.convertRatioByExtraHP / 10000L;

            valueDataInfo.totalAddValueByExtraHP = (int)num2;
            valueDataInfo.addValue += valueDataInfo.totalAddValueByExtraHP;
        }
コード例 #20
0
        public int DynamicAdjustorForMgcEffect(ValueDataInfo vd, ValueDataType type)
        {
            if (type != ValueDataType.TYPE_TOTAL)
            {
                return(this.GenericBaseCalculator(vd, DynamicProperty.Adjustor(vd)));
            }
            int num = this.GenericCalculator(vd, DynamicProperty.Adjustor(vd));

            if (vd.totalEftRatioByMgc > 0)
            {
                num += (vd.totalEftRatioByMgc * this.mActorValue[2].totalValue) / 0x2710;
            }
            return(num);
        }
コード例 #21
0
ファイル: SkillSlot.cs プロジェクト: isoundy000/wzry-1
        public int GetSkillCDMax()
        {
            ValueDataInfo info      = null;
            int           iCoolDown = (int)this.SkillObj.cfgData.iCoolDown;
            int           num2      = this.skillLevel - 1;

            if (num2 < 0)
            {
                num2 = 0;
            }
            iCoolDown += this.SkillObj.cfgData.iCoolDownGrowth * num2;
            if (this.Actor != 0)
            {
                int totalValue = 0;
                info = this.Actor.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_CDREDUCE];
                DebugHelper.Assert(info != null, "Failed get value data");
                if (info == null)
                {
                    return(10);
                }
                if (((info != null) && (this.SlotType != SkillSlotType.SLOT_SKILL_0)) && ((this.SlotType != SkillSlotType.SLOT_SKILL_4) && (this.SlotType != SkillSlotType.SLOT_SKILL_5)))
                {
                    totalValue = info.totalValue;
                }
                int num4 = totalValue + this.changeSkillCDRate;
                if (info.maxLimitValue > 0)
                {
                    num4 = (num4 <= info.maxLimitValue) ? num4 : info.maxLimitValue;
                }
                long num5 = iCoolDown * (0x2710L - num4);
                iCoolDown = (int)(num5 / 0x2710L);
            }
            iCoolDown = (iCoolDown >= 0) ? iCoolDown : 0;
            if (this.SlotType == SkillSlotType.SLOT_SKILL_0)
            {
                info = this.Actor.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_ATKSPDADD];
                DebugHelper.Assert(info != null, "Failed get value data skill 0");
                iCoolDown = (iCoolDown * 0x2710) / (0x2710 + info.totalValue);
                iCoolDown = (iCoolDown >= 0) ? iCoolDown : 0;
            }
            if (((this.Actor != 0) && this.Actor.handle.SkillControl.bZeroCd) && (this.SlotType != SkillSlotType.SLOT_SKILL_0))
            {
                iCoolDown = 0;
            }
            return(iCoolDown);
        }
コード例 #22
0
 public static void ChangeValueData(ref ValueDataInfo valueInfo, RES_VALUE_TYPE type, int val, bool bOffRatio)
 {
     if (type == RES_VALUE_TYPE.TYPE_VALUE)
     {
         if (bOffRatio)
         {
             valueInfo.addValueOffRatio += val;
         }
         else
         {
             valueInfo.addValue += val;
         }
     }
     else if (type == RES_VALUE_TYPE.TYPE_PERCENT)
     {
         valueInfo.addRatio += val;
     }
 }
コード例 #23
0
        public static int Adjustor(ValueDataInfo vdi)
        {
            int baseValue = vdi.baseValue;

            if (vdi.dynamicId < 1)
            {
                return(baseValue);
            }
            ResBattleDynamicProperty config = Singleton <BattleLogic> .instance.dynamicProperty.GetConfig((uint)vdi.dynamicId, RES_BATTLE_DYNAMIC_PROPERTY_VAR.BATTLE_TIME_VAR);

            int num = 10000;

            if (config != null)
            {
                switch (vdi.Type)
                {
                case RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYATKPT:
                    num = config.iAD;
                    break;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCATKPT:
                    num = config.iAP;
                    break;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYDEFPT:
                    num = config.iDef;
                    break;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCDEFPT:
                    num = config.iRes;
                    break;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MAXHP:
                    num = config.iHP;
                    break;

                default:
                    num = 10000;
                    break;
                }
            }
            return(baseValue * num / 10000);
        }
コード例 #24
0
        public static int Adjustor(ValueDataInfo vdi)
        {
            int baseValue = vdi.baseValue;

            if (vdi.dynamicId < 1)
            {
                return(baseValue);
            }
            ResBattleDynamicProperty config = Singleton <BattleLogic> .get_instance().dynamicProperty.GetConfig((uint)vdi.dynamicId, 1);

            int num = 10000;

            if (config != null)
            {
                switch (vdi.Type)
                {
                case 1:
                    num = config.iAD;
                    break;

                case 2:
                    num = config.iAP;
                    break;

                case 3:
                    num = config.iDef;
                    break;

                case 4:
                    num = config.iRes;
                    break;

                case 5:
                    num = config.iHP;
                    break;

                default:
                    num = 10000;
                    break;
                }
            }
            return(baseValue * num / 10000);
        }
コード例 #25
0
ファイル: BuffSkill.cs プロジェクト: TonyDongGuaPi/joework
        private void DealTenacity(PoolObjHandle <ActorRoot> target)
        {
            int           num           = 0;
            ValueDataInfo valueDataInfo = target.get_handle().ValueComponent.mActorValue[29];
            int           totalValue    = valueDataInfo.totalValue;
            int           num2          = totalValue + target.get_handle().ValueComponent.mActorValue.actorLvl *(int)this.battleParam.dwM_Tenacity + (int)this.battleParam.dwN_Tenacity;

            if (num2 != 0)
            {
                num = totalValue * 10000 / num2;
            }
            num += target.get_handle().ValueComponent.mActorValue[17].totalValue;
            int num3 = this.curAction.get_handle().length;

            if (num != 0)
            {
                num3 = num3 * (10000 - num) / 10000;
                this.curAction.get_handle().ResetLength(num3, false);
            }
        }
コード例 #26
0
        private void DealTenacity(PoolObjHandle <ActorRoot> target)
        {
            int           num           = 0;
            ValueDataInfo valueDataInfo = target.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_PROPERTY_TENACITY];
            int           totalValue    = valueDataInfo.totalValue;
            int           num2          = totalValue + target.handle.ValueComponent.mActorValue.actorLvl * (int)this.battleParam.dwM_Tenacity + (int)this.battleParam.dwN_Tenacity;

            if (num2 != 0)
            {
                num = totalValue * 10000 / num2;
            }
            num += target.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_CTRLREDUCE].totalValue;
            int num3 = this.curAction.handle.length;

            if (num != 0)
            {
                num3 = num3 * (10000 - num) / 10000;
                this.curAction.handle.ResetLength(num3, false);
            }
        }
コード例 #27
0
ファイル: DynamicProperty.cs プロジェクト: zbx91/wzry
        public static int Adjustor(ValueDataInfo vdi)
        {
            int baseValue = vdi.baseValue;

            if (vdi.dynamicId < 1)
            {
                return(baseValue);
            }
            ResBattleDynamicProperty config = Singleton <BattleLogic> .instance.dynamicProperty.GetConfig((uint)vdi.dynamicId, RES_BATTLE_DYNAMIC_PROPERTY_VAR.BATTLE_TIME_VAR);

            int iAD = 0x2710;

            if (config != null)
            {
                switch (vdi.Type)
                {
                case RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYATKPT:
                    iAD = config.iAD;
                    goto Label_00A7;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCATKPT:
                    iAD = config.iAP;
                    goto Label_00A7;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_PHYDEFPT:
                    iAD = config.iDef;
                    goto Label_00A7;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MGCDEFPT:
                    iAD = config.iRes;
                    goto Label_00A7;

                case RES_FUNCEFT_TYPE.RES_FUNCEFT_MAXHP:
                    iAD = config.iHP;
                    goto Label_00A7;
                }
                iAD = 0x2710;
            }
Label_00A7:
            return((baseValue * iAD) / 0x2710);
        }
コード例 #28
0
        private void SetSkillSpeed(PoolObjHandle <ActorRoot> user)
        {
            int num = 0;

            if (this.curAction)
            {
                ValueDataInfo valueDataInfo = user.get_handle().ValueComponent.mActorValue[28];
                int           totalValue    = valueDataInfo.totalValue;
                int           num2          = totalValue + user.get_handle().ValueComponent.mActorValue.actorLvl *(int)this.battleParam.dwM_AttackSpeed + (int)this.battleParam.dwN_AttackSpeed;
                if (num2 != 0)
                {
                    num = totalValue * 10000 / num2;
                }
                num += user.get_handle().ValueComponent.mActorValue[18].totalValue;
                if (this.cfgData != null && this.cfgData.bNoInfluenceAnim == 1)
                {
                    num = 0;
                }
                VFactor playSpeed = new VFactor((long)(10000 + num), 10000L);
                this.curAction.get_handle().SetPlaySpeed(playSpeed);
            }
        }
コード例 #29
0
ファイル: BuffSkill.cs プロジェクト: isoundy000/wzry-1
        private void DealTenacity(PoolObjHandle <ActorRoot> target)
        {
            int           inLengthMs = 0;
            int           totalValue = 0;
            int           num3       = 0;
            int           num4       = 0;
            ValueDataInfo info       = null;

            info       = target.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_PROPERTY_TENACITY];
            totalValue = info.totalValue;
            num4       = (int)((totalValue + (target.handle.ValueComponent.mActorValue.actorLvl * this.battleParam.dwM_Tenacity)) + this.battleParam.dwN_Tenacity);
            if (num4 != 0)
            {
                num3 = (totalValue * 0x2710) / num4;
            }
            num3      += target.handle.ValueComponent.mActorValue[RES_FUNCEFT_TYPE.RES_FUNCEFT_CTRLREDUCE].totalValue;
            inLengthMs = this.curAction.handle.length;
            if (num3 != 0)
            {
                inLengthMs = (inLengthMs * (0x2710 - num3)) / 0x2710;
                this.curAction.handle.ResetLength(inLengthMs, false);
            }
        }
コード例 #30
0
ファイル: OrganWrapper.cs プロジェクト: TonyDongGuaPi/joework
        private void ActorMarkProcess(PoolObjHandle <ActorRoot> _inActor, AreaCheck.ActorAction _action)
        {
            if (!_inActor)
            {
                return;
            }
            ActorTypeDef actorType = _inActor.get_handle().TheActorMeta.ActorType;

            if (actorType == ActorTypeDef.Actor_Type_Monster)
            {
                if (_action == AreaCheck.ActorAction.Enter)
                {
                    if (++this._aroundEnemyMonsterCount == 1)
                    {
                        ValueDataInfo valueDataInfo = this.actor.ValueComponent.mActorValue[3] - this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddPhyDef;
                        valueDataInfo = this.actor.ValueComponent.mActorValue[4] - this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddMgcDef;
                    }
                }
                else if (_action == AreaCheck.ActorAction.Leave && --this._aroundEnemyMonsterCount == 0)
                {
                    ValueDataInfo valueDataInfo2 = this.actor.ValueComponent.mActorValue[3] + this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddPhyDef;
                    valueDataInfo2 = this.actor.ValueComponent.mActorValue[4] + this.actor.TheStaticData.TheOrganOnlyInfo.NoEnemyAddMgcDef;
                }
            }
            else if (actorType == ActorTypeDef.Actor_Type_Hero || actorType == ActorTypeDef.Actor_Type_EYE)
            {
                if (_action == AreaCheck.ActorAction.Enter)
                {
                    _inActor.get_handle().HorizonMarker.AddShowMark(3, HorizonConfig.ShowMark.Organ, 1);
                }
                else if (_action == AreaCheck.ActorAction.Leave)
                {
                    _inActor.get_handle().HorizonMarker.AddShowMark(3, HorizonConfig.ShowMark.Organ, -1);
                }
            }
        }